By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
432,247 Members | 871 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 432,247 IT Pros & Developers. It's quick & easy.

asp.net calendar control highlighting special days

P: n/a
Does anybody have a simple vb.net example where you select dates from a
table and highlight them in an asp.net 2.0 calendar?

Oct 13 '06 #1
Share this Question
Share on Google+
1 Reply


P: n/a
there is plenty of them...

all you need to do is using the DayRender of the calendar property and then
check if the day that the control is rendering is the one you want and if it
is, just do whatever you want with that day cell... change background color,
add text on it, change format, etc...

Sub DayRender(ByVal source As Object, ByVal e As DayRenderEventArgs)

If e.Day.Date = myDate Then

' do something

End if

End Sub

so in your case you need to keep the selected values in a DataTable for
example then on the dayRender of the calendar, just loop through your
datatable dates

:-)
--

Bruno Alexandre
KÝbenhavn, Danmark

"a Portuguese in Denmark"

Blog. http://balexandre.blogspot.com/
Photos. http://www.flickr.com/photos/balexandre/
"jobs at webdos" <jo**@webdos.comwrote in message
news:11**********************@m73g2000cwd.googlegr oups.com...
Does anybody have a simple vb.net example where you select dates from a
table and highlight them in an asp.net 2.0 calendar?

Oct 13 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.