Yep this is one of the most simplest functionality that any developer in .Net framework would be looking for.
But why am I blogging about this then??? Okay most of you might have the answer to this one already and there are multiple ways to getting the following functionality in a web page. So the only reason that I am mentioning this issue here is that its simple as ABC, still some people don’t get it right.
In the good old days of ASP you just set the alt attribute of the <img>tag. And the image would show the text as a tooltip when you bring the mouse over it.
Now in ASP. NET while using the ASP .NET Server Controls you just set the Alternate Text attribute of the <asp:image> tag. See its simple as that.
Still if you go on and you are using a grid or a repeater for displaying the image its fine till you get to display the cells dynamically. For the dynamic controls I usually prefer using the HTML-Controls like most of the developers [System.We.UI.HTMLControls.HTMLImage], here you just need to set the alt attribute again.
Or you could use the Web Controls Image control [System.Web.UI.WebControls.Image], again just set the tool-tip by setting the ToolTip property for this control.
Happy Tool Tipping your images. ;P .




‘;’;-0[‘
I was eagerly looking for tooltip to HTMLImage and this article really helped me..
Thanks & Regards,
Eclat.
Fantastic. It really helped me make a nice tooltip!
Gr8 working
Hey Its really Fantastic. It really helped me