Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Web Controls > Changing the color of cell on mouse over event in calendar control

Reply
Thread Tools

Changing the color of cell on mouse over event in calendar control

 
 
Garg
Guest
Posts: n/a
 
      03-16-2007
Hi,

I want to make the color of a cell change in my calendar control,
whenever mouse is brought over that particular cell. How can I achieve
this functionality??

Thanks,
Shivani

 
Reply With Quote
 
 
 
 
marss
Guest
Posts: n/a
 
      03-19-2007

Garg wrote:
> Hi,
>
> I want to make the color of a cell change in my calendar control,
> whenever mouse is brought over that particular cell. How can I achieve
> this functionality??
>
> Thanks,
> Shivani


Here the example:
cell.Attributes["onmouseover"] =
"this.style.backgroundColor='#ff0000';";
cell.Attributes["onmouseout"] =
"this.style.backgroundColor='#0000ff';";

Or if existing background color of the cell is set by the style sheet
or it is inherited from parent element:
cell.Attributes["onmouseover"] =
"this.oldBGColor=this.style.backgroundColor;this.s tyle.backgroundColor='#ff0000';";
cell.Attributes["onmouseout"] =
"this.style.backgroundColor=this.oldBGColor;";

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Changing font color from current font color to black color Kamaljeet Saini Ruby 0 02-13-2009 04:58 PM
VOIP over VPN over TCP over WAP over 3G Theo Markettos UK VOIP 2 02-14-2008 03:27 PM
Changing color to a button with the mouse over Paul HTML 14 12-02-2007 10:37 PM
Datagrid control to change the row color on Mouse click event karunakar ASP .Net 1 01-31-2005 09:33 AM
ASP.Net Datagrid get Cell Contents on mouse click or mouse down Davisro ASP .Net 2 04-23-2004 07:18 PM



Advertisments