Click here to Skip to main content
15,892,480 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
dear sir,

when i am selecting imageButton i am changing imageUrl after this on click of submit button i want to display id's of that selected imageButton ... how can i get that id's onClick event of submit button....
plz help...
Posted
Comments
Asgard25 25-Mar-14 5:35am    
Your going to have to use javascript, get element(imagebutton) id and assign that to a hidden label and then get that labels text from the code behind. All this can be done using javascript.onclick when the button is clicked.
V. 25-Mar-14 10:20am    
I'm not sure what you want exactly and if this is a client side control or server side and which of those id's you want. In the code behind some controls have the clientid property you can use for the client id and I think the name property will return the server side id of the control. You could do it through javascript as well, but probably you'll need to make sure the client id is not auto-generated in that case.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900