ASP.NET AlternateText Property
Complete Image Control Reference
Definition and Usage
The AlternateText property is used to set or return the alternate text of an image.
This property specifies the text to display if the image is not available.
The alternate text displays as a ToolTip if your browser supports it
(Internet Explorer)
Syntax
|
<asp:Image AlternateText="text" runat="server" /> |
| Attribute |
Description |
| text |
Specifies an alternate text for the image |
Example
The following example sets the AlternateText for an Image control (image file does not exist):
<form runat="server">
<asp:Image id="Img1" ImageUrl="missing_img.gif"
runat="server" AlternateText="Image Text" />
</form>
|
Show example »
|
Complete Image Control Reference
The Creators of XMLSpy are Pleased to Announce
|