Find ASP.NET's Image Server Control OnClick or OnServerClick event

So you can'tt find the ASP.NET's OnClick (WebControls) or the OnServerClick (HtmlControls) event ?

Clue: Remember the ASP.NET's ImageButton type?

The ImageButton is the .NET type that represents a clickable image. It derives from the Image type and exposes an event called Command.

Programmatically you can add the Command event like this:

ImageButton img = new ImageButton();
img.Command += new CommandEventHandler(MyImgEvent_Command);

Problem solved!
Reblog this post [with Zemanta]

Be a part of our private list!

Enter your e-mail and access The Rabbit Way's exclusive offers.

Enter your Email

Preview | Powered by FeedBlitz

Or read this related articles

Widget by Hoctro | Jack Book

No comments:

Post a Comment