I’ve build an application that offers a drop down box with choices generated from a database using asp. Making a choice in the first box populates a second box with additional appropriate choices. That’s all working fine but I want the user to be able to recall previously made choices for subsequent editing. I’ve managed to get the first box to show the value selected in a previous session but I can’t figure out how to get the code dynamically written for the second box to show one value as selected. Here’s a snippet of code that writes the code for the second box. If someone could suggest how I modify this to allow me to make one value selected based upon an asp if/then test, I’d greatly appreciate it. Thanks!
sJavaScript = sJavaScript & _
“document.f1.RealtyLName.options[document.” & _
“f1.RealtyLName.options.length] = new Option(‘” & _
junk & “‘,'” & rs02(“RealtyLNameID”) & _
“‘);” & _
vbCrlf