For Next Loop

Results 1 to 3 of 3

Thread: For Next Loop

  1. #1
    m3alem Guest

    Default For Next Loop

    Can someone tell me why this is not working. "state"&i="checked" <BR>I am trying to assign state1=checked or state2 =checked dynamically. When it gets to this line "state"&i="checked", it gives me an error. Thanks for the help <BR>&#060;% <BR>dim i <BR>for i=1 to 2 <BR>mo=("checkbox"&i) <BR>if request(mo) &#060;&#062; "" then <BR> "state"&i="checked" <BR>end if <BR>next <BR><BR>%&#062;

  2. #2
    Steve W Guest

    Default RE: For Next Loop

    Try the following:<BR><BR>"state" & i & "=checked"<BR><BR>Good luck!

  3. #3
    m3alem Guest

    Default RE: For Next Loop

    Thanks steve, but it doesn&#039t work. The error msg i am getting<BR>Error Type:<BR>Microsoft VBScript compilation (0x800A0400)<BR>Expected statement<BR>/test/radio.asp, line 21<BR>"state" &i &"=checked"<BR><BR><BR>

Posting Permissions

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