*************************************************
i think (and this is by looking at the above code) that you don't understand that the ASP's VBscript runs on the server before the html gets put to the client....
*****************************************
I do and I had the adodb and the call at the top in my original code.
Sometimes when you try what you know to solve a problem and is not working, then you begin to tinker with the code to see if you can get lucky and resolve the problem.
Such was the case with me with this code.
Well, I have put it back at the top and I am still getting this error"
"object required" around this code:
If NOT staffset.EOF Then staffset.MoveFirst
Do Until staffset.EOF
'lets dynamically add to the javascript
Response.Write "selbox.options[selbox.options.length] = new Option('" & staffset("empid") & "','" & staffset("lname") & "');" & vbCrLf
staffset.MoveNext
Loop
This is frustrating.
If I do a static dropdown where the values are hardcoded, it works but I have to do it this way because there is an email program attached to my code which sends email based on someone's empid.
If I do it static, the empid will have to be removed.