+ Reply to Thread
Results 1 to 2 of 2

Return the earliest day of a month

  1. #1
    Registered User
    Join Date
    04-10-2004
    Posts
    23

    Return the earliest day of a month

    Please see attached spreadsheet, I need to set formula to the green cells (B5-9), correct results are shown in blue cells (D5-8).

    The problem is that the data series is a dynamic one, as I download the data from Bloomberg, so as I open the file everyday, it will automatically insert today's price to row 11. Therefore, formulars in cells D5-8 won't work as the day is moving.

    I have set the formula in cell B5 to calculate the current MTD (i.e. from 1 July until today), I can use the same method for June, May and April returns, but the problem is that for example, beginning of June doesn't start with 1 June, it starts with 2 June and also ending of May is not 31 May but 30 May. Formula I set at cells A6-8 using EOMONTH. So I can't the same method, how shall I set the formula then?

    thanks
    Attached Files Attached Files

  2. #2
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320
    first day of the month B1 =DATE(YEAR(A1), MONTH(A1), 1)

    last day of month B1=DATE(YEAR(A1), MONTH(A1)+1, 1)-1


    and even first monday in month


    Please Login or Register  to view this content.
    Last edited by martindwilson; 07-07-2008 at 05:04 AM.

+ 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