View Full Version : ASP VBscript public sub help

01-28-2007, 08:44 PM
Hey all i need a way for the user, when they choose a store from a cbobox to populate another cbobox depending on what the user choose in the first cbobox.

I cant seem to execute a public sub once i put the onchange="" on the first cbobox.

<select name="cboSelect" class="FieldStyleDropDown" id="cboSelect" onchange="FillBox">
<option value=" "> </option>
<option value="GP">Gunbarrel Point</option>

Public Sub FillBox()
blah blah blah...

Am i leaving something out???

Thanks! :)

01-29-2007, 12:43 PM
onchange is a client-side event handler; fired by the browser. Anything in <% %> tags is server-side code, that runs at the server. If you're not sure about the distinction between those, I'd recommend that you go through some basic ASP tutorials (http://www.w3schools.com/asp/default.asp). Once you've done that, you could try searching this forum for terms like "change", "second" and "dropdown" - you'll find several (http://www.codingforums.com/showthread.php?t=104189)threads (http://www.codingforums.com/showthread.php?t=104287)that go into the problem you're having in great detail.

01-30-2007, 01:56 PM
There are several threads here with different methods for dropdowns