TO GET THE USER CONTROL ID
-
Hi, I want to know how will i get the id of the user control whose instance i have created in a form like:
NOW INSIDE a USER CONTROL JAVA SCRIPT I WANT THE ID "UserControl1" .....how will i get it? Thkx
Hi! Test to click "view source" on the web form, when looking at it from your webbrowser. You will then see that there's no ID:s visible to the user. If you write a typical JavaScript (client-side), you usually don't have any easy way to retrieve the ID. What you might want to try, would be to set a string value to the name of the control in the HTML-code, and then use the Javascript to retrieve the value of the string, rather then try to get the ID from the webcontrol. Hope this helps you, :) /_henrik Henrik Sternberg, Cambridge Technolgy Partners, Germany www.ctp.com/ce henrik.sternberg@ctp.nospam.com (take away nospam)