|
-
Sep 23rd, 2002, 02:32 AM
#1
Thread Starter
Hyperactive Member
querystrings and autopostback
How do I have a contol postback and include a querystring?
I have a listbox and when the user clicks a selection, I want to pass listbox.selecteditem.text as a querystring.
Thanks for any info.
-
Sep 23rd, 2002, 04:40 AM
#2
Hyperactive Member
Do an event handler for its onClick event and post the selected items as a querystring
William T
Software Architect / Chief Software Developer
Softwaremaker.Net Pte Ltd
http://www.Softwaremaker.net
*** Things are always the darkest before they go pitch black ***
-
Sep 23rd, 2002, 04:16 PM
#3
Thread Starter
Hyperactive Member
Can you give some example code please? The only way I know how is
VB Code:
response.write "<a href='myasp.asp?dir=d:/'>link</a>"
I don't know what to put in the click event
VB Code:
private sub ListBox1_onclick()
???????
end sub
Thx
-
Sep 23rd, 2002, 05:48 PM
#4
Hyperactive Member
visual basic code:--------------------------------------------------------------------------------
private sub ListBox1_onclick()
Response.Redirect ("SomePage.aspx?id=" & ListBox1.SelectedIndex)
end sub
--------------------------------------------------------------------------------
William T
Software Architect / Chief Software Developer
Softwaremaker.Net Pte Ltd
http://www.Softwaremaker.net
*** Things are always the darkest before they go pitch black ***
-
Sep 23rd, 2002, 05:49 PM
#5
Thread Starter
Hyperactive Member
OK, That is nice and easy.
Thanks.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|