Re: ASP Loop in wrong place????

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: Fawke101 (guy_at_ANTIbradflack.SPAMcom)
Date: 03/25/04


Date: Thu, 25 Mar 2004 17:14:34 -0000

OK, below is the code for the entire table (inc. ASP functions)
If you build it in dreamweaver or something it should show you what its all
about - note the extra row for the end of loop.
Sorry, its alot of code....

*****
<table width="700" align="center" id="dataTable" name="dataTable"cols="8">
          <tr>
            <td width="279"><a href="javascript: sortTable(0)"><div
align="left"></div><font color="#004080" size="1" face="Verdana, Arial,
Helvetica, sans-serif"><strong>Manager </strong></font></div></a></td>
            <td width="10"><div align="left"><font color="#003399" size="1"
face="Verdana, Arial, Helvetica, sans-serif"></font></div></td>
            <td width="88"><a href="javascript: sortTable(2)"><div
align="right"><font color="#004080" size="1" face="Verdana, Arial,
Helvetica, sans-serif"><strong>Total</strong></font></div></a></td>
            <td width="22"><div align="left"><font color="#003399" size="1"
face="Verdana, Arial, Helvetica, sans-serif"></font></div></td>
            <td width="15"><font color="#003399" size="1" face="Verdana,
Arial, Helvetica, sans-serif">&nbsp;</font></td>
            <td width="116"><!---<a href="javascript: sortTable(5)">---><div
align="right"><font color="#004080" size="1" face="Verdana, Arial,
Helvetica, sans-serif"><strong>Income<br>
            All Clients </strong></font></div><!---</a>---></td>
            <td width="17"><font color="#003399" size="1" face="Verdana,
Arial, Helvetica, sans-serif">&nbsp;</font></td>
            <td width="117"><!---<a href="javascript: sortTable(7)">---><div
align="right"><font color="#004080" size="1" face="Verdana, Arial,
Helvetica, sans-serif"><strong>Income <br>
            New</strong></font></div><!---</a>---></td>
          </tr>
          <tr>
            <td><font color="#000000" size="2" face="Verdana, Arial,
Helvetica, sans-serif">
              <%Dim RS, strArea
strArea = Replace(Session("lstArea"),"'","''")

Set RS = DataConnection.Execute("SELECT manager, all_customers, income,
income_new_customers FROM vw_Summary_Area WHERE vw_Summary_Area.Area='" &
strArea & "'")
do until RS.EOF
%>
              <a href= "summary_manager.asp?manager=<%=RS("manager")%>">
              <% =RS("manager")%>
              </a>
              </font>

    </td>
            <td><font color="#000000" size="2" face="Verdana, Arial,
Helvetica, sans-serif">&nbsp;</font></td>
            <td><div align="right"><font color="#000000" size="2"
face="Verdana, Arial, Helvetica, sans-serif">
                <% =RS("all_customers")%>
                <em></em></font></div></td>
            <td><font color="#000000" size="2" face="Verdana, Arial,
Helvetica, sans-serif">&nbsp;</font></td>
            <td>&nbsp;</td>
            <td><div align="right"><font color="#000000" size="2"
face="Verdana, Arial, Helvetica, sans-serif">
                <% =formatcurrency(RS("income"),2)%>
            </font></div></td>
            <td>&nbsp;</td>
            <td><div align="right"><font color="#000000" size="2"
face="Verdana, Arial, Helvetica, sans-serif">
                <% =formatcurrency(RS("income_new_customers"),2)%>
            </font></div></td>
          </tr>
          <tr>
            <td><font color="#000000" size="2" face="Verdana, Arial,
Helvetica, sans-serif">
              <%RS.MoveNext
Loop%>
            </font></td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
          </tr>
        </table>
*****

--
Thanks in advance
Fawke
Please remove ANTI and SPAM
from my email address before emailing me.
www.bradflack.com
"Jeff Cochran" <jcochran.nospam@naplesgov.com> wrote in message
news:4063102b.5308483@msnews.microsoft.com...
> On Thu, 25 Mar 2004 16:18:03 -0000, "Fawke101"
> <guy@ANTIbradflack.SPAMcom> wrote:
>
> >Hi There,
> >
> >I have a table with 3 rows. 1st has the table/column headers, 2nd
contains
> >the column data and the 3rd is where the loop for the SQL statement lies.
> >
> >I also have a JS sort function on there (which int complete, but thats
> >another post/story) which sorts the data A-Z or Z-A. The problem i am
having
> >is that the loop row (which isnt visible on the ASP page, as its ASP) is
> >being sorted as well.
> >
> >Rather than excluding the row from sorting, i was wondering if i could
scrap
> >it altogether?, but when i try and move the loop out of the row, all the
> >data goes crazy, all over the shop.
> >
> >Basically, where can i put the RS.Movenext Loop statement that will still
> >dsiplay the data still in the same way in my table (rather than the last
> >row)
> >
> >I appreciated this is a weird question, if you would like me to post the
> >code for my table thats fine.
>
> More than fine, probably required.  Though it may be a client side
> issue.
>
> Jeff


Relevant Pages

  • Re: ASP Loop in wrong place????
    ... Thanks however as i will build my ASP apps dynamically in the future. ... >>about - note the extra row for the end of loop. ... > Helvetica, sans-serif";} ... > ' Get your record set before beginning to create the table ...
    (microsoft.public.inetserver.asp.general)
  • Re: PHP and Dreamweaver CCSes
    ... font: Geneva, Verdana, Arial, helvetica, sans-serif; ...
    (comp.infosystems.www.authoring.html)
  • Re: Css Quest
    ... 11px Verdana, Arial, Helvetica, sans-serif; ...
    (microsoft.public.frontpage.programming)
  • Re: Class not working for textbox.
    ... Probably better to use cssClass so you can program ... font-family: Verdana, Arial, Helvetica, sans-serif; ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: ASP, looping, and stored procedures.... error 800a0bb9 ...
    ... > page PER loop. ... The looping goes by month from and to dates selected ... > In pure ASP the page takes about 15 seconds. ... > Oh, and by the way, the test box has SQL server and IIS on it. ...
    (microsoft.public.inetserver.asp.db)