Solved

How to Capture the Value of the Date Clicked on on a MonthCalender Control in a DateTime Variable By Clicking on Date

Posted on 2011-02-22
2
530 Views
Last Modified: 2013-11-26
I have a MonthCalendar Control ( named MonthCalendar1 ) on a Form1 in a Visual Basic Project in  Visual Studio 2008. I would like to capture the Value of the Date I click on this MonthCalender1 control in a DateTime  Variable  named  myDate.
I would appreciate help with code that would achieve this for me. Please also let me know in which event of this MonthCalendar Control I should put this code. Thank you for your help in anticipation.

0
Comment
Question by:FaheemAhmadGul
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 9

Accepted Solution

by:
Misbah earned 100 total points
ID: 34955795
Use DataChanged Event:
 

private void monthCalendar1_DateChanged(object sender, DateRangeEventArgs e)
{
     DateTime selectedDate = e.Start;
        
}

Open in new window

0
 

Author Closing Comment

by:FaheemAhmadGul
ID: 34955848
Many thanks. I am very grateful. Regards
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In my previous two articles we discussed Binary Serialization (http://www.experts-exchange.com/A_4362.html) and XML Serialization (http://www.experts-exchange.com/A_4425.html). In this article we will try to know more about SOAP (Simple Object Acces…
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
THe viewer will learn how to use NetBeans IDE 8.0 for Windows to perform CRUD operations on a MySql database.
The viewer will learn how to synchronize PHP projects with a remote server in NetBeans IDE 8.0 for Windows.

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question