checking of a checkbox

Results 1 to 2 of 2

Thread: checking of a checkbox

  1. #1
    Join Date
    Dec 1969

    Default checking of a checkbox

    I thaught i had this process down, but can&#039;t get it. i just need to check a check, and no matter what i do, all show up as checked.<BR><BR>// sql<BR>select * from...<BR>set RSList...<BR><BR>// checkbox<BR>&#060;input type="checkbox" name="WBE" value="1"<BR>&#060;% <BR>If RSList("WBE") &#060;&#062; "" Then <BR> Response.Write "CHECKED" <BR>End IF <BR>%&#062; <BR>&#062;<BR><BR>my page shows it as checked even the db field in unchecked.

  2. #2
    Join Date
    Dec 1969

    Default RE: checking of a checkbox

    Assuming an Access db and the field is set to yes/no then the easiest way is:<BR><BR><BR> If rslist("WBE") = "1" Then <BR> response.write "&#060;input type=checkbox name=WBE value=1 checked&#062;"<BR> else<BR> response.write "&#060;input type=checkbox name=WBE value=1&#062;"<BR> end if<BR><BR><BR>The value will never be "" that&#039;s why you&#039;re getting box checked always

Posting Permissions

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