TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Test
NA
58
51.1k
How to get months difference between two dates in c#
Sep 11 2019 3:06 AM
I have two date fields where i need to caluculate difference in months between those two dates how can i do this.Below is my formula
(start.Year * 12 + start.Month) - (end.Year * 12 + end.Month);
Expected Result
Start Date End Date Need to get output as
08/28/2019 09/02/2019 1
06/01/2019 09/02/2019 4
01/02/2019 03/02/2019 3
01/02/2019 03/05/2019 3
Reply
Answers (
11
)
How to increase height of Popup window ?
How to Retrieve null datetime in a texbox from gridview ?