listbox control

Results 1 to 2 of 2

Thread: listbox control

  1. #1
    Join Date
    Dec 1969

    Default listbox control

    Is there a way to force a user to select an option from a list box? My list box appears after a user selects an item from a dropdown list and then clicks submit. The list box then appears with another button. I can&#039;t get the required field validator function to fire just at the second submit button. Any ideas?<BR><BR>An If listbox.selectedvalue.value = "" then<BR>gives me an error message about "not being set to an instance of an object"<BR><BR>Any thoughts on the best way to tackle this?

  2. #2
    Join Date
    Dec 1969

    Default RE: listbox control

    See this article:<BR><BR>I think the custom control is the only way to validate this. Unless, of course, you just want to do a server check, then you just do the following:<BR><BR>if listbox.selectedindex = -1 then<BR>&#039; The user did not make a selection<BR>end if<BR><BR>Good luck!<BR><BR>JM

Posting Permissions

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