get generated id of a control?

S

soni2926

hi,
in .net when i have a hyperlink control in a datagrid, i set it's ID
on the page to Hyperlink1. but when i check it's ID when viewing the
source of the web page i get this:
dg_ctl02_Hyperlink1
isn't there someway to know what .net generated before the ID i put in
the code, i mean this part:
dg_ctl02_
 
C

Cowboy \(Gregory A. Beamer\)

Well, if you do like most people, you simply add the dg_ctl02_ in a hard
coded manner. ;-)

Mark has already answered the correct way. While you are still server side,
pull the ClientID.

--
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA

Subscribe to my blog
http://feeds.feedburner.com/GregoryBeamer#

or just read it:
http://feeds.feedburner.com/GregoryBeamer

********************************************
| Think outside the box! |
********************************************
 

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

Top