Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
Classic ASP Basics For beginner programmers starting with "classic" ASP 3, pre-".NET." NOT for ASP.NET 1.0, 1.1, or 2.0
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Basics section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old January 5th, 2006, 08:09 AM
Registered User
Join Date: Jan 2006
Location: dharwad, karnataka, India.
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to rjkulkarni2001 Send a message via AIM to rjkulkarni2001 Send a message via MSN to rjkulkarni2001 Send a message via Yahoo to rjkulkarni2001
Default duration between dates

i want to find the duration between two dates, and it should be in format as given below,
date1:12/12/2005 dd/mm/yyyy format
date2 :12/01/2006
then duration should be difference of two dates
and format like
0 years,1 month 0 days

thank u

Reply With Quote
  #2 (permalink)  
Old January 5th, 2006, 07:19 PM
Friend of Wrox
Points: 6,664, Level: 34
Points: 6,664, Level: 34 Points: 6,664, Level: 34 Points: 6,664, Level: 34
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
Join Date: Jan 2004
Location: Sydney, NSW, Australia.
Posts: 1,870
Thanks: 12
Thanked 20 Times in 20 Posts
Send a message via AIM to mat41

Please do not cross post:


Your other post asks for a 'in asp.net with vb.net code behind' solution - what exactly are you after?

If its classic ASP/VBScript you could use the dateDiff function:

------------cut n paste code-----------------
  dim dateOne,dateTwo
  dateOne = "12/12/2005"
  dateTwo = "12/01/2006"
  response.write DateDiff("yyyy", dateOne, dateTwo) & " Years, " & DateDiff("m", dateOne, dateTwo) & " Months, " & DateDiff("d", dateOne, dateTwo) & " Days"

Wind is your friend
Reply With Quote

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
days-from-duration Dinghus XSLT 1 November 21st, 2007 04:05 AM
seconds-from-duration outspaced XSLT 2 April 3rd, 2007 08:51 AM
date duration in dotnet rjkulkarni2001 Classic ASP Basics 1 January 5th, 2006 07:06 PM
visitor duration per page esemerda Pro PHP 2 September 8th, 2005 01:38 PM

All times are GMT -4. The time now is 12:05 PM.

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.