je********@gmail.com wrote:
Hello everyone,
I have what I thought was a simple script but I cant figure it out.
Anyway, I want to set the selected item of a drop down list with
information i am recieving from request.querystring. Seems like this
is a case of when learning asp.net first is a hindrance to what i
want to do. Im looking for something to the effect of,
Request.Form("dd_eventdate")= Request.QueryString("event")
thanks,
I'm not clear. Are you doning this in classic asp or asp.net?
FWIW, what you've written is not valid even in asp.net: the Request
collections are read-only.
Classic ASP answer:
Remember, asp code generates html that is sent to the client via the
Response object. Other than that (and the Request object of course) there is
no interaction with the client.
It appears you have a SELECT element whose name is "dd_eventdate" ... how is
the list of options for the SELECT generated/populated? If it's done using
server-side code, then you should incorporate the querystring variable's
value into the code building that option list.
If it is hard-coded or built via client-side code, then you will need to use
client-side script to select the option. That, of course, is outside the
purview of this newsgroup - try .scripting.jscript.
--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.