Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Calendar ignores colour change of non-selectable date text in IE...

Status
Not open for further replies.

psaxelby

Programmer
Sep 24, 2009
1
GB
Hi,

Can anyone help me with this problem please?

I'm having my first go at customising a control - and this problem has me stumped. I've searched in these forums & the net to no avail.

I've derived a class from the Calendar control and am trying to stop dates from other months from showing up.

The code that made sense to me...
....
day.IsSelectable = false;
cell.ForeColor = cell.BackColor;
....

... just leaves the text grey. I tried all sorts of ways of hiding the text, but nothing works. What's really strange is that when I set the forecolour to say 'white', the greyed text looks slightly thinner, and if I change the background to a dark colour the grey text has a shadow of whatever colour I set the forecolour to.

I've spent ages trying to solve this problem with my code, but I now think it's a problem with IE. If I view the control in Chrome for example, the code works as I thought it should.

Does anyone know of this problem and how to get around it please?



Many thanks,

Paul

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top