|
-
Dec 6th, 2008, 07:59 PM
#1
Thread Starter
Addicted Member
[RESOLVED] mouse over text
is there an easy way (in visual basic language) to display some text when you put your mouse over a button - like the help text that appears in other windows applications. like when you put your mouse over button 1 a little message appears at the mouse saying "Refresh".
thanks...
-
Dec 6th, 2008, 08:47 PM
#2
Re: mouse over text
Set the ToolTip property/attribute.
<asp:Button ID="Button1" runat="server" Text="Button" ToolTip="Refresh"/>
-
Dec 6th, 2008, 08:49 PM
#3
Thread Starter
Addicted Member
Re: mouse over text
thanks
do you have the code in vb language?
-
Dec 6th, 2008, 08:53 PM
#4
Re: mouse over text
If the button is declared on the aspx page the code would simply be
Me.Button1.ToolTip = "Refresh"
-
Dec 6th, 2008, 10:28 PM
#5
Thread Starter
Addicted Member
-
Dec 6th, 2008, 10:29 PM
#6
Thread Starter
Addicted Member
Re: mouse over text
but which event do i put that code in?
-
Dec 7th, 2008, 02:12 PM
#7
Re: mouse over text
You should add that text in the ASP.Net page itself rather than a code behind (since it's content oriented). If the link / button is dynamically generated then add them during the Page Load event.
If your dynamic links are generated in an event then add the ToolTip there instead of Page Load.
Fyi, text that appears when you hover are title attributes in html. The ToolTrip will automatically be renamed title when the html is generated. The alt attribute will sometimes do this but it wasn't meant to.
-
Dec 7th, 2008, 05:23 PM
#8
Thread Starter
Addicted Member
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|