PC Review


Reply
Thread Tools Rate Thread

Days360 Formula in VBA error

 
 
Brian A
Guest
Posts: n/a
 
      7th Mar 2008
I need to write a macro which looks at a column of dates, takes the Minimum
date (earliest) and the maximum date(latest) and figure out how many weeks
have passed between the two. I recorded a macro, but that limits me by
forcing me to select the exact cells. It is fine on one set of data but I
need to use this over and over with a variable number of data rows. Any
suggestions?
 
Reply With Quote
 
 
 
 
Niek Otten
Guest
Posts: n/a
 
      7th Mar 2008
No macro needed

With the dates in Column B:

=(MAX(B:B)-MIN(B:B))/7

Decide how you'd like to round

--
Kind regards,

Niek Otten
Microsoft MVP - Excel

"Brian A" <(E-Mail Removed)> wrote in message news:15DEED13-6C00-40BA-9261-(E-Mail Removed)...
|I need to write a macro which looks at a column of dates, takes the Minimum
| date (earliest) and the maximum date(latest) and figure out how many weeks
| have passed between the two. I recorded a macro, but that limits me by
| forcing me to select the exact cells. It is fine on one set of data but I
| need to use this over and over with a variable number of data rows. Any
| suggestions?


 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Entering Days360 in Table formula Bob Arnett Microsoft Excel Misc 2 15th Oct 2009 09:02 PM
Days360 error between July & August 2008 Roy M. Lee Microsoft Excel Crashes 4 10th Aug 2008 05:06 PM
DAYS360 =?Utf-8?B?Q2FuZGVudGNvIENyZWF0aXZlIENvbGxlY3Rpb24= Microsoft Excel Worksheet Functions 4 12th Apr 2007 09:48 PM
DAYS360 =?Utf-8?B?SmFuIEJ1Y2tsZXk=?= Microsoft Excel Worksheet Functions 3 21st Jul 2005 10:44 PM
Inserting DAYS360 formula Deepak Microsoft Access 1 8th Jun 2004 11:24 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 12:56 AM.