I'm hoping someone here might help me with this.
I'm putting the finishing touches on my intranet web app, and I'm adding
some simple JavaScript to my VB.Net Webforms.
This works:
Button1.Attributes.Add("onmouseover", "this.style.backgroundColor=""Blue""")
Button1.Attributes.Add("onmouseout", "this.style.backgroundColor=""Navy""")
And this works:
Hyperlink1.Attributes.Add("onmouseover", "this.style.fontWeight=""Bold""")
Hyperlink1.Attributes.Add("onmouseout", "this.style.fontWeight=""Normal""")
But this doesn't:
Hyperlink2.Attributes.Add("onmouseover", "this.style.COLOR=""Blue""")
Hyperlink2.Attributes.Add("onmouseout", "this.style.COLOR=""Navy""")
I'd like the hyperlink text to sort of "glow" by changing the font to the
lighter color, but it does nothing. I've hacked at it for an hour or so and
tried .color, .forecolor, .foreground, .foregroundcolor, .fontcolor, and so
on. . . I googled for example code and found plenty, but none just changing
the font color.
So either this simply can't be done this way, or I need a clue.
TIA 2 1789
Just a thought but you might look into hover. You could put that in a style
sheet for sure.
"wazoo" <wa***@NOSPAMnycap.rr.com> wrote in message
news:eh****************@twister.nyroc.rr.com... I'm hoping someone here might help me with this.
I'm putting the finishing touches on my intranet web app, and I'm adding some simple JavaScript to my VB.Net Webforms.
This works: Button1.Attributes.Add("onmouseover",
"this.style.backgroundColor=""Blue""") Button1.Attributes.Add("onmouseout",
"this.style.backgroundColor=""Navy""") And this works: Hyperlink1.Attributes.Add("onmouseover", "this.style.fontWeight=""Bold""") Hyperlink1.Attributes.Add("onmouseout",
"this.style.fontWeight=""Normal""") But this doesn't: Hyperlink2.Attributes.Add("onmouseover", "this.style.COLOR=""Blue""") Hyperlink2.Attributes.Add("onmouseout", "this.style.COLOR=""Navy""")
I'd like the hyperlink text to sort of "glow" by changing the font to the lighter color, but it does nothing. I've hacked at it for an hour or so
and tried .color, .forecolor, .foreground, .foregroundcolor, .fontcolor, and
so on. . . I googled for example code and found plenty, but none just
changing the font color.
So either this simply can't be done this way, or I need a clue.
TIA
Actually "COLOR" was typed for emphasis, I was typing "Color" - still
incorrect, and for the same reason: JScript is case-sensitive
"color" works. CSS will need to wait for the next project, I need to get
this one off my desk.
"vMike" <Mi************@nospam.gewarren.com.delete> wrote in message
news:bn**********@ngspool-d02.news.aol.com... Just a thought but you might look into hover. You could put that in a
style sheet for sure.
"wazoo" <wa***@NOSPAMnycap.rr.com> wrote in message news:eh****************@twister.nyroc.rr.com... I'm hoping someone here might help me with this.
I'm putting the finishing touches on my intranet web app, and I'm adding some simple JavaScript to my VB.Net Webforms.
This works: Button1.Attributes.Add("onmouseover", "this.style.backgroundColor=""Blue""") Button1.Attributes.Add("onmouseout", "this.style.backgroundColor=""Navy""") And this works: Hyperlink1.Attributes.Add("onmouseover",
"this.style.fontWeight=""Bold""") Hyperlink1.Attributes.Add("onmouseout",
"this.style.fontWeight=""Normal""") But this doesn't: Hyperlink2.Attributes.Add("onmouseover", "this.style.COLOR=""Blue""") Hyperlink2.Attributes.Add("onmouseout", "this.style.COLOR=""Navy""")
I'd like the hyperlink text to sort of "glow" by changing the font to
the lighter color, but it does nothing. I've hacked at it for an hour or so
and tried .color, .forecolor, .foreground, .foregroundcolor, .fontcolor, and so on. . . I googled for example code and found plenty, but none just changing the font color.
So either this simply can't be done this way, or I need a clue.
TIA
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: addi |
last post by:
All,
I have seen the feature on many sites and would like to implement it for
myself as well, where if a mouse is moved over a hyperlink, it gets
underlined. For example, in my code, if the...
|
by: Peter Eriksson |
last post by:
I am making a link with the HyperLink-class like this:
HyperLink link = new HyperLink();
link.NavigateUrl = "http://www.page.com";
link.Text = "Some text";...
|
by: wazoo |
last post by:
I'm hoping someone here might help me with this.
I'm putting the finishing touches on my intranet web app, and I'm adding
some simple JavaScript to my VB.Net Webforms.
This works:...
|
by: Whitney Yiu |
last post by:
I am using a DataGrid, and have bound it to some data (not using the quick
design way though -- i hard coded it using sql data adapter, command, etc).
Anyways, I have a column that is a link, and i...
|
by: Peter Morris |
last post by:
Newbie q.
how do I change the image url for a hyperlink on mouseover?
I have a menubar, and I want to highlight the selected item.
|
by: Dave |
last post by:
I've been given a flash banner and told to make it a hyperlink.
I tried this: <script type="text/javascript">
Document.getElementById("flashcontent").onclick = function(){...
|
by: cps_farzin |
last post by:
I am using ASP.Net and C# in development of my webapp. I want to user
hyperlink <a href=...as link but when I do, I loose the finger pointer on
mouse over. How do I get that back? Any ideas?!...
|
by: Mat |
last post by:
How do you modify the color of an hyperlink when your mouse go over it?
<asp:HyperLink
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: ryjfgjl |
last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
| |