29 Aug 2013

How to Change colour on mouseover.

Hello.
The code to change colour (textbox,button,cell,tr etc). You can make a class in HTML design form and then call that function on code file.
Step 1:-
First of all make a css class as shown below:



<style type="text/css">

.normalRow
{
background-color:Red;
cursor:pointer;

.highlightRow
{
background-color:white;
cursor:pointer;
}
</style>
Step 2:-
Now call this css in code file like (this is for table row TR):

 tr1.Attributes.Add("onmouseover", "this.className=('highlightRow');");
 tr1.Attributes.Add("onmouseout", "this.className=('normalRow');");

No comments:

Post a Comment

How to Create WEBSITE DESIGN

Way2finder Technologies is a web design studio that offers corporate web design and custom web design. Our website designers offer cheap w...