Microsoft
Software
Hardware
Network
Question : Capture ClientID of a linkbutton sender
I have a bunch of linkbuttons on a webform where I need to do something based on the ClientID of the linkbutton clicked on. The click event of all the linkbuttons is served by the following codebehind:
protected void MenuItemClick(object sender, EventArgs e)
{
}
How can the clientID of the linkbutton sender be captured in the above code?
Thanks for your help.
Answer : Capture ClientID of a linkbutton sender
First Convert the sender in the Control Type ot os coming from Eg.
Button Btn = (Button)sender;
//Now you can get the client ID as follows:
Btn.ClientID
Hope it helps.
Random Solutions
How do I check if a window is already open or give it focus using Flex/Flash
Setting up exchange
CX600 FLARE 2.05.600.5.007 - upgrade procedure to 2.19?
#tables always in tempdb only?
Cisco IDS vs Juniper IPD 250
Adding an if statement
Vlookup with exact number format
Multiple $(document).ready() jquery conflicting
Translate web site
Cross Domain Policy