Articles
DevASP - ASP and XML Articles, Samples, Toturials, Sample Chapters and resources for Developers Sunday, September 21, 2014
Home
Articles & Samples
Dev Search
Sample Chapters
Link to US
Contact
Search Directory
Applications
Articles & Samples
Components
Community
Database
Developer Sites
Downloads
Hosting Services
Introduction
Knowledge Base
Sample Chapters
WebCasts
ASP Directory
Applications
Articles & Samples
Components
Developer Sites
Knowledge Base
Sample Chapters
WebCasts
XML Directory
Applications
Articles & Samples
Developer Sites
Error, Bugs & Fixes
Downloads
Introduction
Knowledge Base
Sample Chapters
WebCasts

FREE 12 month online training for ASP.NET & MS Expression Studio and a Free copy of MS Expression Web with Windows Server Purchase

Home > Search > Knowledge Base > General Articles
How to find difference between two Dates in C# or VB.NET ?       
Total Hits: 483  |  Today: 0 Author: Mary Mathew       Rating:  
Read Reviews | Write Review |              Your Rating: 

It was an easy job with classic VB to find difference between 2 dates or times. Even though it is not very difficult, it is a tricky and confusing thing in C# and VB.NET.

See the following sample code, which demonstrates how to calculate the difference between two DateTime objects using C# syntax.

What's New at DevASP
02/24  Extending the Win Forms Binding S..
02/24  Managing FTP Transfers from an AS..
02/24  Using OpenSearch to Create a Mult..
02/24  Designing N-Tiered Data Access La..
02/24  Building a .NET Console Applicati..
02/24  Implementing the .netTiers Templa..
02/24  Implementing the .netTiers Templa..
02/24  Getting Started with the ASP.NET ..
02/24  An Introduction to Code Snippets ..
02/24  An Introduction to Code Snippets ..
02/24  Sharing Controls Across Different..
02/24  Building an Enhanced ASP.NET Grid..
02/24  Editing .NET Configuration Files ..
02/24  Using SyncToy v2.0 for Web Site D..
02/24  An Introduction to the Microsoft ..
02/24  An Introduction to Windows Server..
02/24  A Sneak Peek of Visual Studio 201..
02/24  Putting Windows Server 2008 Serve..
02/24  Using the Microsoft URL Rewrite M..
02/24  New Object Oriented Features in C..
 

DevASP - Privacy - Disclaimer
Copyright 2008 DevASP.com