ASP.NET(vb.net) & ImageButton - asp:ImageButton - asp:ImageButton : Enables you to handle user clicks in an image, which gives you functionality similar to an image map.
ShotDev Focus:
- ASP.NET(vb.net) & ImageButton - asp:ImageButton
Tag Control :
<asp:ImageButton id="ImageButton1" ImageUrl="string" Command="Command" CommandArgument="CommandArgument" CausesValidation="true | false" OnClick="OnClickMethod" runat="server"/>
Example
ImageButton.aspx
<%@ Page Language="VB" %> <script runat="server"> Sub Page_Load(sender As Object,e As EventArgs) Me.ImageButton1.ImageURL = "images.gif" Me.ImageButton1.ToolTip = "Submit" End Sub Sub ImageButton1_Click(sender As Object, e As ImageClickEventArgs) Me.lblText1.Text = Me.txtTextBox1.Text End Sub </script> <html> <head> <title>ShotDev.Com Tutorial</title> </head> <body> <form runat="server"> <asp:TextBox id="txtTextBox1" runat="server"></asp:TextBox> <asp:ImageButton id="ImageButton1" onclick="ImageButton1_Click" runat="server"></asp:ImageButton> <hr /> <asp:Label id="lblText1" runat="server"></asp:Label> </form> </body> </html>
Screenshot