473,327 Members | 2,074 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,327 software developers and data experts.

Changing color of hyperlink when mouse over it

When I move my mouse over a hyperlink component, the hyperlink does not
change color.

How do I change the color of a hyperlink when the mouse goes over the
hyperlink?
or
Change the color of a button component when the mouse goes over the button?

I am using Microsfot Visual c#.net Version 7.1.3008

Thanks
Nov 16 '05 #1
5 12674
Hi there... That event happens on the client side so you need a script to
perform the action requested. You can also define a stylesheet and reference
it from the script (this allows you changing colors and appeareance of the
object without recompiling your solution). Hope this can help you.

Regards,

--
Angel J. Hernández M.
MCP - MCAD - MCSD - MCDBA
http://groups.msn.com/desarrolladoresmiranda
http://ajhsis.net

"Martha" <Ma****@discussions.microsoft.com> escribió en el mensaje
news:14**********************************@microsof t.com...
When I move my mouse over a hyperlink component, the hyperlink does not
change color.

How do I change the color of a hyperlink when the mouse goes over the
hyperlink?
or
Change the color of a button component when the mouse goes over the
button?

I am using Microsfot Visual c#.net Version 7.1.3008

Thanks

Nov 16 '05 #2
I'm pretty new at this so where do I add the script ?
Do I add the scrip In the code behind section or add the script directly in
the HTML section of the Webform1.aspx?
Is there any example that shows one how to do this?
Thank you,
Martha

"Angel J. Hernández M." wrote:
Hi there... That event happens on the client side so you need a script to
perform the action requested. You can also define a stylesheet and reference
it from the script (this allows you changing colors and appeareance of the
object without recompiling your solution). Hope this can help you.

Regards,

--
Angel J. Hernández M.
MCP - MCAD - MCSD - MCDBA
http://groups.msn.com/desarrolladoresmiranda
http://ajhsis.net

"Martha" <Ma****@discussions.microsoft.com> escribió en el mensaje
news:14**********************************@microsof t.com...
When I move my mouse over a hyperlink component, the hyperlink does not
change color.

How do I change the color of a hyperlink when the mouse goes over the
hyperlink?
or
Change the color of a button component when the mouse goes over the
button?

I am using Microsfot Visual c#.net Version 7.1.3008

Thanks


Nov 16 '05 #3
You can add it in the html section of your webform. For more information
about this topic you can check this article too.

http://msdn.microsoft.com/library/de...sidescript.asp

Regards,
--
Angel J. Hernández M.
MCP - MCAD - MCSD - MCDBA
http://groups.msn.com/desarrolladoresmiranda
http://ajhsis.net

"Martha" <Ma****@discussions.microsoft.com> escribió en el mensaje
news:F7**********************************@microsof t.com...
I'm pretty new at this so where do I add the script ?
Do I add the scrip In the code behind section or add the script directly
in
the HTML section of the Webform1.aspx?
Is there any example that shows one how to do this?
Thank you,
Martha

"Angel J. Hernández M." wrote:
Hi there... That event happens on the client side so you need a script
to
perform the action requested. You can also define a stylesheet and
reference
it from the script (this allows you changing colors and appeareance of
the
object without recompiling your solution). Hope this can help you.

Regards,

--
Angel J. Hernández M.
MCP - MCAD - MCSD - MCDBA
http://groups.msn.com/desarrolladoresmiranda
http://ajhsis.net

"Martha" <Ma****@discussions.microsoft.com> escribió en el mensaje
news:14**********************************@microsof t.com...
> When I move my mouse over a hyperlink component, the hyperlink does not
> change color.
>
> How do I change the color of a hyperlink when the mouse goes over the
> hyperlink?
> or
> Change the color of a button component when the mouse goes over the
> button?
>
> I am using Microsfot Visual c#.net Version 7.1.3008
>
> Thanks


Nov 16 '05 #4
Hi Angel,
Finally figured it out:
For a hyperlink - to change the color when mouse moves over the hyperlink:

<asp:HyperLink id="HyperLink4" runat="server" BorderStyle="None"
NavigateUrl="http://www.cnn.com"
BorderWidth="0px"
onmouseover="this.style.backgroundColor='yellow'"
onmouseout="this.style.backgroundColor='green'"
HyperLink</asp:HyperLink> I think there is another way to add the same code but in the code behind
section by using attributes but at this point, I am not sure how to do it.
In any case it works for now.
Thank you,
Martha
"Angel J. Hernández M." wrote:
You can add it in the html section of your webform. For more information
about this topic you can check this article too.

http://msdn.microsoft.com/library/de...sidescript.asp

Regards,
--
Angel J. Hernández M.
MCP - MCAD - MCSD - MCDBA
http://groups.msn.com/desarrolladoresmiranda
http://ajhsis.net

"Martha" <Ma****@discussions.microsoft.com> escribió en el mensaje
news:F7**********************************@microsof t.com...
I'm pretty new at this so where do I add the script ?
Do I add the scrip In the code behind section or add the script directly
in
the HTML section of the Webform1.aspx?
Is there any example that shows one how to do this?
Thank you,
Martha

"Angel J. Hernández M." wrote:
Hi there... That event happens on the client side so you need a script
to
perform the action requested. You can also define a stylesheet and
reference
it from the script (this allows you changing colors and appeareance of
the
object without recompiling your solution). Hope this can help you.

Regards,

--
Angel J. Hernández M.
MCP - MCAD - MCSD - MCDBA
http://groups.msn.com/desarrolladoresmiranda
http://ajhsis.net

"Martha" <Ma****@discussions.microsoft.com> escribió en el mensaje
news:14**********************************@microsof t.com...
> When I move my mouse over a hyperlink component, the hyperlink does not
> change color.
>
> How do I change the color of a hyperlink when the mouse goes over the
> hyperlink?
> or
> Change the color of a button component when the mouse goes over the
> button?
>
> I am using Microsfot Visual c#.net Version 7.1.3008
>
> Thanks


Nov 16 '05 #5
It's ok... Happy programming ;-)
--
Angel J. Hernández M.
MCP - MCAD - MCSD - MCDBA
http://groups.msn.com/desarrolladoresmiranda
http://ajhsis.net

"Martha" <Ma****@discussions.microsoft.com> escribió en el mensaje
news:F0**********************************@microsof t.com...
Hi Angel,
Finally figured it out:
For a hyperlink - to change the color when mouse moves over the hyperlink:

<asp:HyperLink id="HyperLink4" runat="server" BorderStyle="None"
NavigateUrl="http://www.cnn.com"
BorderWidth="0px"
onmouseover="this.style.backgroundColor='yellow'"
onmouseout="this.style.backgroundColor='green'"
HyperLink</asp:HyperLink>

I think there is another way to add the same code but in the code behind
section by using attributes but at this point, I am not sure how to do it.
In any case it works for now.
Thank you,
Martha
"Angel J. Hernández M." wrote:
You can add it in the html section of your webform. For more information
about this topic you can check this article too.

http://msdn.microsoft.com/library/de...sidescript.asp

Regards,
--
Angel J. Hernández M.
MCP - MCAD - MCSD - MCDBA
http://groups.msn.com/desarrolladoresmiranda
http://ajhsis.net

"Martha" <Ma****@discussions.microsoft.com> escribió en el mensaje
news:F7**********************************@microsof t.com...
> I'm pretty new at this so where do I add the script ?
> Do I add the scrip In the code behind section or add the script
> directly
> in
> the HTML section of the Webform1.aspx?
> Is there any example that shows one how to do this?
> Thank you,
> Martha
>
> "Angel J. Hernández M." wrote:
>
>> Hi there... That event happens on the client side so you need a
>> script
>> to
>> perform the action requested. You can also define a stylesheet and
>> reference
>> it from the script (this allows you changing colors and appeareance of
>> the
>> object without recompiling your solution). Hope this can help you.
>>
>> Regards,
>>
>> --
>> Angel J. Hernández M.
>> MCP - MCAD - MCSD - MCDBA
>> http://groups.msn.com/desarrolladoresmiranda
>> http://ajhsis.net
>>
>>
>>
>> "Martha" <Ma****@discussions.microsoft.com> escribió en el mensaje
>> news:14**********************************@microsof t.com...
>> > When I move my mouse over a hyperlink component, the hyperlink does
>> > not
>> > change color.
>> >
>> > How do I change the color of a hyperlink when the mouse goes over
>> > the
>> > hyperlink?
>> > or
>> > Change the color of a button component when the mouse goes over the
>> > button?
>> >
>> > I am using Microsfot Visual c#.net Version 7.1.3008
>> >
>> > Thanks
>>
>>
>>


Nov 16 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Geoff Soper | last post by:
I'm trying to dynamically change the cursor of a couple of maps over an image. Basically the image is in an online photo system where there is a rotate mode. In this mode clicking on the left or...
1
by: Badboy36 | last post by:
Hello user from googlegroups, i made a microsoft access database with front and backend. i created the backend in microsoft access97. for the frontend i made two versions (one for microsoft...
4
by: Andreas Meffert | last post by:
Hello, How can I change the Type of a field in a table from Memo to hyperlink? I import a table from Oracle to Access 2003. After that, the field type of some hyperlink-fields is "Memo". How...
9
by: Leigh Kendall | last post by:
I can't find any issue in the MS KB, but I'm experiencing the following problem which seems to be specific to IE5, and NOT any other version of IE 5.5+ or NN 6+. Issue: I'm using an asp.net...
2
by: David Hearn | last post by:
I have an ImageButton control that I am using on one of my pages. Sometimes, this button will act as a button and redirect users to another page. But sometimes, it will just act as an image...
1
by: Nathan Sokalski | last post by:
I am using the ImageUrl property of the Hyperlink control to create a graphical Hyperlink. However, I want to change the size of the image I am using, but the generated HTML places the width/height...
31
by: jcrouse | last post by:
Is there a quick and easy way to change the color of a label controls border from the default black to white? Thank you, John
0
by: lechatthierry | last post by:
Is it possible to block a mouse event on an Hyperlink with a general script event? This is quite troublesome for me. I am trying to find a way to block the windows shortcut SHIFT + MOUSE LEFT...
1
by: Neko | last post by:
Is it possible to block a mouse event on an Hyperlink with a general script event? This is quite troublesome for me. I am trying to find a way to block the windows shortcut SHIFT + MOUSE LEFT...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.