JavaScript Onclick firing a button (C#)

J

Jer

Has anybody ever used JavaScript to fire a button? I want a user to be able
to click anywhere in a row to be able to make a selection. I use mouseovers
and mouseouts to highlight the selected row. Currently the only way I know
how to allow a user to click anywhere on a row is to register a JavaScript
OnClick script which redirects back to the same page with a specified
querystring (like an id). I don't want to use querystrings within the same
page though.

J
 
E

Eliyahu Goldin

On server side use either ItemDataBound or PreRender event to set the same
javascript handler for "onclick" client event to all cells in the same row.
Pass the row key value to the handler. It is not clear what sort of button
you want to fire and what for.

Eliyahu
 

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

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top