Change forecolor for specific dates for datetimepicker value
-
25 มกราคม 2555 23:18How do you change the forecolor for specific dates using a datetimepicker control? I have researched, and I am unable to find a solution. Thanks.
Quanny- ย้ายโดย Esther FanMicrosoft 23 เมษายน 2555 1:00 (From:Visual Studio Class Designer)
ตอบทั้งหมด
-
27 มกราคม 2555 5:29
Hi Quanny,
Welcome to the MSDN forum.
As far as I know, there is no existence method or property to reach your goals. But the MonthCalendar Control has the BoldedDate method to bold the special date. Here is some information and sample code about MonthCalendar.BoldedDates Property: http://msdn.microsoft.com/en-us/library/system.windows.forms.monthcalendar.boldeddates.aspx
If you insist to use DateTimePicker control, I’m afraid that you need to custom it by yourself. Here are some samples, and hope them help.
DateTimePicker Color: http://social.msdn.microsoft.com/Forums/en-US/Vsexpressvcs/thread/5d95b931-0edc-4f6c-8aa7-6d8eb14780a0
Change Background color & Font of DateTimePicker: http://social.msdn.microsoft.com/Forums/en-US/vbgeneral/thread/d3d289f5-9978-4143-88ee-4d1a689d07b9
By the way, this queue is about Visual Studio Class Designer. So would you like to show witch programming language you will use to solve your issue, VB or C#?
If you have any additional questions, please feel free to let me know.
Mark Liu-lxf [MSFT]
MSDN Community Support | Feedback to us
- ทำเครื่องหมายเป็นคำตอบโดย Mark Liu-lxf 7 กุมภาพันธ์ 2555 8:28
-
7 กุมภาพันธ์ 2555 8:28
Hi Quanny,
We haven’t heard from you for a while. I’d like to mark my reply as answer firstly. If you have any additional questions, you also can unmark the replay and post your question here.
Sorry for any inconvenience and have a nice day.
Mark Liu-lxf [MSFT]
MSDN Community Support | Feedback to us