+ Reply to Thread
Results 1 to 2 of 2

Calculating weeks from two dates

  1. #1
    Registered User
    Join Date
    07-18-2011
    Location
    Washington, DC
    MS-Off Ver
    Excel 2007
    Posts
    24

    Calculating weeks from two dates

    I'm trying to calculate the number of weeks between two dates. I would like to count part of a week as a full week so I need to round up.

    [CODE]BegDate = DateValue(Range("B6").Value)
    Enddate = DateValue(Range("B7").Value)
    weeks = RoundUp(((Enddate - BegDate) / 7), 0)
    Range("G6").Select
    ActiveCell.Formula = weeksCODE]

    Is there a "RoundUp" function in VBA I can use? How should I change my code.

  2. #2
    Registered User
    Join Date
    07-18-2011
    Location
    Washington, DC
    MS-Off Ver
    Excel 2007
    Posts
    24

    Re: Calculating weeks from two dates

    I also need to put each week (represented by Week1, Week2, etc.) in a column starting say in cell B:9.

    Thanks for the help.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1