Ask a Question related to ASP.NET General, Design and Development.
-
Tor Inge Rislaa #1
How to change onmouseover and onmouseout dynamically
Hi, I control the style of a button like the code below
Private Sub Change_Color()
Button1.Style("BACKGROUND-COLOR") = "#CEB57B"
Button1.Style("COLOR") = "White"
End Sub
How can I do the same with Button1's onmouseover and onmouseout style?
(Language VB.NET)
T.I.Rislaa
Tor Inge Rislaa Guest
-
Change Content Dynamically
I'm trying to find a way to change the contents of a table (calendar) that I have nested in a DIV. without loading a new page. In other words, go... -
Reliable onmouseout in IE
Been pounding my head a bit over mouse out events in IE. I need a general solution to the following sort of situation. Designer has an element... -
Change DataNavigateUrlField dynamically
Hi guys, let's see if someone can give me a small hand with this.... i'm populating a dataset that sometimes changes 1 or 2 columns depending on... -
Dynamically change URL in Web Service
Dear Al I am now also facing a problem on changing URL in web reference. Firstly, i added a web reference in my project, and then i change the... -
dynamically change
I need to know how to modify the <asp:BoundColumn/> to N/A when the datafield value comes in as negative quantity and color it different on the... -
S. Justin Gengo #2
Re: How to change onmouseover and onmouseout dynamically
Tor,
Button1.Attributes.Add("onmouseover",
"javascript:this.style.color='White';this.style.ba ckground-color='#CEB57B';"
)
Button1.Attributes.Add("onmouseout", "javascript: ... ;")
Should do it for you.
(I'm not positive I've specified the styles properly. I'm borrowing the
format from a cursor change that I do:
"javascript:this.style.cursor='pointer';" but I'm pretty sure it will work.
Sincerely,
--
S. Justin Gengo, MCP
Web Developer
Free code library at:
[url]www.aboutfortunate.com[/url]
"Out of chaos comes order."
Nietzche
"Tor Inge Rislaa" <tor.inge.nospam@rislaa.no> wrote in message
news:%23%23Eog4BXDHA.1384@TK2MSFTNGP10.phx.gbl...> Hi, I control the style of a button like the code below
>
> Private Sub Change_Color()
> Button1.Style("BACKGROUND-COLOR") = "#CEB57B"
> Button1.Style("COLOR") = "White"
> End Sub
>
> How can I do the same with Button1's onmouseover and onmouseout style?
>
> (Language VB.NET)
>
> T.I.Rislaa
>
>
>
S. Justin Gengo Guest
-
John Saunders #3
Re: How to change onmouseover and onmouseout dynamically
You don't want the "javascript:" unless you're putting the code into the
href attribute of an anchor tag. Just add "this.style.color...".
--
John Saunders
Internet Engineer
[email]john.saunders@surfcontrol.com[/email]
"S. Justin Gengo" <sjgengo@aboutfortunate.com> wrote in message
news:u6619PCXDHA.3248@tk2msftngp13.phx.gbl..."javascript:this.style.color='White';this.style.ba ckground-color='#CEB57B';"> Tor,
>
> Button1.Attributes.Add("onmouseover",
>work.> )
>
> Button1.Attributes.Add("onmouseout", "javascript: ... ;")
>
> Should do it for you.
>
> (I'm not positive I've specified the styles properly. I'm borrowing the
> format from a cursor change that I do:
> "javascript:this.style.cursor='pointer';" but I'm pretty sure it will>
> Sincerely,
>
> --
> S. Justin Gengo, MCP
> Web Developer
>
> Free code library at:
> [url]www.aboutfortunate.com[/url]
>
> "Out of chaos comes order."
> Nietzche
> "Tor Inge Rislaa" <tor.inge.nospam@rislaa.no> wrote in message
> news:%23%23Eog4BXDHA.1384@TK2MSFTNGP10.phx.gbl...>> > Hi, I control the style of a button like the code below
> >
> > Private Sub Change_Color()
> > Button1.Style("BACKGROUND-COLOR") = "#CEB57B"
> > Button1.Style("COLOR") = "White"
> > End Sub
> >
> > How can I do the same with Button1's onmouseover and onmouseout style?
> >
> > (Language VB.NET)
> >
> > T.I.Rislaa
> >
> >
> >
>
John Saunders Guest
-
Jerry III #4
Re: How to change onmouseover and onmouseout dynamically
And remember to set Content-Script-Type, either in HTTP headers or through a
META tag...
Jerry
"John Saunders" <john.saunders@surfcontrol.com> wrote in message
news:%23o2H3LDXDHA.1620@TK2MSFTNGP12.phx.gbl..."javascript:this.style.color='White';this.style.ba ckground-color='#CEB57B';"> You don't want the "javascript:" unless you're putting the code into the
> href attribute of an anchor tag. Just add "this.style.color...".
> --
> John Saunders
> Internet Engineer
> [email]john.saunders@surfcontrol.com[/email]
>
> "S. Justin Gengo" <sjgengo@aboutfortunate.com> wrote in message
> news:u6619PCXDHA.3248@tk2msftngp13.phx.gbl...>> > Tor,
> >
> > Button1.Attributes.Add("onmouseover",
> >> work.> > )
> >
> > Button1.Attributes.Add("onmouseout", "javascript: ... ;")
> >
> > Should do it for you.
> >
> > (I'm not positive I've specified the styles properly. I'm borrowing the
> > format from a cursor change that I do:
> > "javascript:this.style.cursor='pointer';" but I'm pretty sure it will>> >
> > Sincerely,
> >
> > --
> > S. Justin Gengo, MCP
> > Web Developer
> >
> > Free code library at:
> > [url]www.aboutfortunate.com[/url]
> >
> > "Out of chaos comes order."
> > Nietzche
> > "Tor Inge Rislaa" <tor.inge.nospam@rislaa.no> wrote in message
> > news:%23%23Eog4BXDHA.1384@TK2MSFTNGP10.phx.gbl...> >> > > Hi, I control the style of a button like the code below
> > >
> > > Private Sub Change_Color()
> > > Button1.Style("BACKGROUND-COLOR") = "#CEB57B"
> > > Button1.Style("COLOR") = "White"
> > > End Sub
> > >
> > > How can I do the same with Button1's onmouseover and onmouseout style?
> > >
> > > (Language VB.NET)
> > >
> > > T.I.Rislaa
> > >
> > >
> > >
> >
>
Jerry III Guest



Reply With Quote

