+ Reply to Thread
Results 1 to 4 of 4

The Monday of the previous week with VBA

Hybrid View

  1. #1
    Gérard Ducouret
    Guest

    The Monday of the previous week with VBA

    Hello,

    I have a date from Monday to Friday in the current week. I need to calculate
    the date of the Monday of the previous week in VBA.
    How can I do that ?
    Thanks a lot

    Gérard



  2. #2
    Bob Phillips
    Guest

    Re: The Monday of the previous week with VBA

    =A1-WEEKDAY(A1,2)+1

    --
    HTH

    Bob Phillips

    (remove nothere from email address if mailing direct)

    "Gérard Ducouret" <gerard.ducouret@wanadooNOSPAM.fr> wrote in message
    news:uBm9hZVQGHA.2012@TK2MSFTNGP14.phx.gbl...
    > Hello,
    >
    > I have a date from Monday to Friday in the current week. I need to

    calculate
    > the date of the Monday of the previous week in VBA.
    > How can I do that ?
    > Thanks a lot
    >
    > Gérard
    >
    >




  3. #3
    Tom Ogilvy
    Guest

    Re: The Monday of the previous week with VBA

    Date-(weekday(date,2)+6)

    --
    Regards,
    Tom Ogilvy


    "Gérard Ducouret" <gerard.ducouret@wanadooNOSPAM.fr> wrote in message
    news:uBm9hZVQGHA.2012@TK2MSFTNGP14.phx.gbl...
    > Hello,
    >
    > I have a date from Monday to Friday in the current week. I need to

    calculate
    > the date of the Monday of the previous week in VBA.
    > How can I do that ?
    > Thanks a lot
    >
    > Gérard
    >
    >




  4. #4
    Gérard Ducouret
    Guest

    Re: The Monday of the previous week with VBA

    Thanks a lot Tom!
    That works !

    Gérard

    "Tom Ogilvy" <twogilvy@msn.com> a écrit dans le message de
    news:OPBFllVQGHA.3272@tk2msftngp13.phx.gbl...
    > Date-(weekday(date,2)+6)
    >
    > --
    > Regards,
    > Tom Ogilvy
    >
    >
    > "Gérard Ducouret" <gerard.ducouret@wanadooNOSPAM.fr> wrote in message
    > news:uBm9hZVQGHA.2012@TK2MSFTNGP14.phx.gbl...
    > > Hello,
    > >
    > > I have a date from Monday to Friday in the current week. I need to

    > calculate
    > > the date of the Monday of the previous week in VBA.
    > > How can I do that ?
    > > Thanks a lot
    > >
    > > Gérard
    > >
    > >

    >
    >




+ 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