Click here to Skip to main content
Rate this: bad
Please Sign up or sign in to vote.
See more: .NET3.5
i have two datetimepicker in two windows form. if i select date in datetimepicker in first form the second datetimepicker in second form display 6 month date after date select in datetimepicker in first display 6 month differnce. how can i do that?
Posted 7-Aug-12 4:59am

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

You need to add 6 months to the date of first picker. You can do either way mentioned below.

Following would help you:
MSDN: DateTime.AddMonths Method [^]


MSDN: DateTime.Add Method [^]
MSDN: TimeSpan Structure[^]
Manohar Khillare at 8-Aug-12 10:53am
i have two forms and each form contain one datetimepicker
Sandeep Mewara at 8-Aug-12 11:41am
So? Whenever you go from one form to other take the value and use it!

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 6,434
1 OriginalGriff 6,178
2 Peter Leow 2,534
3 Abhinav S 2,274
4 Maciej Los 2,268

Advertise | Privacy | Mobile
Web02 | 2.8.150414.1 | Last Updated 7 Aug 2012
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100