Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - Paging not working - urgent help needed
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Paging not working - urgent help needed

 Post Reply Post Reply
Author
simflex View Drop Down
Groupie
Groupie
Avatar

Joined: 10 November 2002
Location: United States
Status: Offline
Points: 63
Post Options Post Options   Thanks (0) Thanks(0)   Quote simflex Quote  Post ReplyReply Direct Link To This Post Topic: Paging not working - urgent help needed
    Posted: 09 September 2004 at 8:47am

Hello all,

I have tried just about everything that I know to get the paging to work on this code, but it isn't.

I swear that when I tested this code last night on my pc, it worked fine; why itsn't working anymore, I don't know.

The culprit here is the next Block, previous block buttons.

Sorry to dump the entire code because I am not sure where it may have broken.

I am not getting any errors but it just won't.

Just a bit more info on what I am trying to do.

I select system_D from the db into recordset.

If there are more than one blockIDs associated with a particular systemID, the page indicates how many blockIDs there are and displays a message that says: processing block1 of ...(however many).

So far so go.

The problem comes when I try to go the next blockID.

Nothing happens.

Here is the code. Any help would be greatly, greatly appreciated.

I have a 1pm demo of this app today and this is really hurting right now.

 

[code]

This is page2 of the code Tarwn helped out with.

Tarwn helped with page1 of it.

This code works fine as far as doing what I wanted it to do.

However, the only issue that I have is the layout.

I have been struggling to re-arrange it but to avail.

I would like the layout to look like this:

Fullname:______________ System ID:______ Project No:____
From/At:______________ To:________ No. of Segments:____

Then the other formats can stay as they are:
So far it isn't working.

One other *little* problem is that the "Next Block" functionality is not working.

Any help would be greatly appreciated.

Sorry about the long code:


CODE
<%
' from the prior page, we get the requested SystemID:
systemID = Request("TxtsysID")
full_Name = Request("TxtprojectName")

       dim Conn,SQLstr
       Function OpenDBFConn(Path)
       Dim Conn: Set Conn = CreateObject("ADODB.Connection")
        Conn.Open "Provider=Microsoft.Jet.OLEDB.4.0;" & _
                    "Data Source=" & Path & ";" & _
                    "Exten ded Properties=""DBASE IV;"";"
       Set OpenDBFConn = Conn
       End Function

      Dim DBConn
      Set DBConn = OpenDBFConn("c:\arcgis")
      'Open recordset from basins table
      Dim rs
      Set rs = DBConn.Execute("SELECT Full_Name, geo_oid FROM cline.dbf where system_ID =" & SystemID)


' How many rows are there?
BlockCount = UBound(rows,2) + 1

' okay, ready to generate form...
%>

<FORM Name="MainForm" Method=Post Action="sam2.asp" onFilt="return validateForm(this);">
<INPUT Type=HIDDEN Name="blockCount" Value="<%=blockCount%>" >
<INPUT Type=HIDDEN Name="systemID" Value="<%=systemID%>" >

<table CellPadding=5>
<tr>
    <td align="right">System ID:</td>
    <td><%=systemID%></td >
    <td align="right">Project No:</td>
    <td><input type="text" size=5 name="projID" value=""></td>
</tr>
  <tr>
    <td width="101"><font size="2" color="Black" face="Arial"><i>From/At:</i></font>< /td>
    <td><input type="text" name="TxtfromAt" size="20" maxlength="20" value=""></td>
    <td align="right"><font size="2" color="Black" face="Arial"><i>To:</i></font></td&g t;
    <td><input type="text" name="Txt_To" size="20" maxlength="20" value=""></td>
    <td align="right"><font size="2" color="Black" face="Arial"><i>No. of Segments:</i></font></td>
    <td><%=blockCount%></ td>
  </tr>
</table>
<hr>
<table CellPadding=5>
<tr>
    <td colSpan=10>
    Processing block <span ID="ID_curBlock">1</span>
    of <%=blockCount%> blocks.
    </td>
</tr>
<%
' now generate hidden divs for each row of data:
For row = 0 To UBound(rows,2)
    full_Name  = rows(COL_NAME,row)
    geo_oid   = rows(COL_BLKID,row)
%>
    <INPUT Type=Hidden Name="Row_<%=row%>" Value="<%=blockID%>">
    <INPUT Type=Hidden Name="Fullname_<%=row%>" Value="<%=fullName%>">
    <tr ID="ROWA_<%=row%>" style="display: none">
        <td>Bl ock ID:</td>
        <td>&l t;%=geo_oid%></td>
        <td>Fu llname:</td>
        <td>&l t;%=full_Name%></td>
    </tr>
    <tr ID="ROWB_<%=row%>" style="display: none">
        <td>Fr om:</td>
        <td>&l t;input type="text" size=10 name="from_<%=row%>" value=""></td>
        <td>To :</td>
        <td>&l t;input type="text" size=10 name="to_<%=row%>" value=""></td>
    </tr>
    <tr ID="ROWC_<%=row%>" style="display: none">
        <td>Di rection:</td>
        <td>&l t;input type="text" size=5 name="direction_<%=row%>" value=""></td>
        <td>To :</td>
        <td>&l t;input type="text" size=5 name="directionTo_<%=row%>" value=""></td>
    </tr>
<%
Next ' next row
%>
</TABLE>

<INPUT Type=Button Name="prior" Value="<<prior block" onFilt="goBlock(-1);">
&nbsp; &nbsp; &nbsp; &nbsp;
<INPUT Type=Submit Value="Process Everything!">
&nbsp; &nbsp; &nbsp; &nbsp;
<INPUT Type=Button Name="next" Value="next block>>" onFilt="goBlock(1);">
</FORM>

<SCRIPT Language="JavaScript">
// check one set of block info for validity
// This simple minded check just looks for blank values
// You get to fix it to do the right thing
//
function checkOne(which)
{
    var frm = document.MainForm;

    var fldFrom = frm.elements["from_" + which];
    var fldTo   = frm.elements["to_" + which];
&n

Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.