Repost:hyperlink

A

ashoo

Guys!
I am trying to use a dropdownlist click event in my header
page to link to my main page in a frameset type of form.

I try to link to my main page with a hyperlink control.It
works fine. But I would like to use the click event of my
dropdownlist to do the samething. so I thought if could
trigger the clik event of the hyperlink within my
dropdownlist click event it could work. But I am not sure
how to set it up.

Note: redirect to the frameset form does not work.

Thanks for helping!
 
C

Chris Jackson

I presume you are talking about doing this on the client, since there is no
server-side click event for a hyperlink control. (It renders HTML that
handles this on the client.) Since you have frames, you should consider that
each frame holds a separate HTML page (by the time it gets to the client) so
it's a lot harder to navigate the frameset from the server than it would be
from the client. When it gets to the client, the object model is aware of
what it contains - on the server, it isn't.

So, what you want to do is to handle this using JavaScript on the client.
Rather than using a DropDownList control, use a <select> control (HtmlSelect
in the class library) and use an onchange client side event handler to
navigate to a new page in your other frame.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,774
Messages
2,569,599
Members
45,170
Latest member
Andrew1609
Top