Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3

Thread: Small Thing

  1. #1
    New to the CF scene
    Join Date
    Jan 2005
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Small Thing

    i am making a while statement that is <% while (num < 6) %>
    but i need to know how to get the feild out of the database that the while state ment is currently on.
    There are feilds Card1, Card2, Card3, ect all the way to 10 in the database but i only need the first 6.
    is there anyway i can go <%=rs("Card1")%> but instead of the 1 in Card1 can it get the value of num that the while state ment is currently on?
    i tried to guess something like <%=rs("Card<%=num%>")%> but i cannot figure it out.

    thx

  • #2
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    11,038
    Thanks
    0
    Thanked 250 Times in 246 Posts
    <%=rs("Card" & num)%>

  • #3
    New to the CF scene
    Join Date
    Jan 2005
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts
    thx a ton glenn


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •