+ Reply to Thread
Results 1 to 8 of 8

Fill all date of a month according to criteria

  1. #1
    Forum Contributor HaroonSid's Avatar
    Join Date
    02-28-2014
    Location
    india
    MS-Off Ver
    Excel 2013
    Posts
    2,080

    Post Fill all date of a month according to criteria

    hi,
    i want to fill all dates of a month in range A4:A35

    while Month = range("A2").value
    and
    Year = range("A3").value

    for example
    range a2 = april
    range a3 = 2017

    then range a4:a35 value =

    01/05/2017 Monday
    02/05/2017 Tuesday
    03/05/2017 Wednesday
    04/05/2017 Thursday
    05/05/2017 Friday
    06/05/2017 Saturday
    07/05/2017 Sunday
    08/05/2017 Monday
    09/05/2017 Tuesday
    10/05/2017 Wednesday
    11/05/2017 Thursday
    12/05/2017 Friday
    13/05/2017 Saturday
    14/05/2017 Sunday
    15/05/2017 Monday
    16/05/2017 Tuesday
    17/05/2017 Wednesday
    18/05/2017 Thursday
    19/05/2017 Friday
    20/05/2017 Saturday
    21/05/2017 Sunday
    22/05/2017 Monday
    23/05/2017 Tuesday
    24/05/2017 Wednesday
    25/05/2017 Thursday
    26/05/2017 Friday
    27/05/2017 Saturday
    28/05/2017 Sunday
    29/05/2017 Monday
    30/05/2017 Tuesday
    31/05/2017 Wednesday

    thank you in advance
    Use Code-Tags for showing your code :
    Please mark your question Solved if there has been offered a solution that works fine for you
    If You like solutions provided by anyone, feel free to add reputation using STAR *

  2. #2
    Forum Guru Sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,489

    Re: Fill all date of a month according to criteria

    Surely you mean if A2 = may
    Last edited by Sintek; 05-05-2017 at 06:46 AM.
    Good Luck...
    I don't presume to know what I am doing, however, just like you, I too started somewhere...
    One-day, One-problem at a time!!!
    If you feel I have helped, please click on the [★ Add Reputation] to left of post window...
    Also....Add a comment if you like!!!!
    And remember...Mark Thread as Solved...
    Excel Forum Rocks!!!

  3. #3
    Forum Contributor HaroonSid's Avatar
    Join Date
    02-28-2014
    Location
    india
    MS-Off Ver
    Excel 2013
    Posts
    2,080

    Re: Fill all date of a month according to criteria

    Yes

    a2 = may

  4. #4
    Forum Guru Sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,489

    Re: Fill all date of a month according to criteria

    This is the best I could come up with; Works if A2 = month No and not month name: Adapted from code found in Source: Stack overflow

    Please Login or Register  to view this content.

  5. #5
    Forum Contributor HaroonSid's Avatar
    Join Date
    02-28-2014
    Location
    india
    MS-Off Ver
    Excel 2013
    Posts
    2,080

    Re: Fill all date of a month according to criteria

    thank you
    its working

  6. #6
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,663

    Re: Fill all date of a month according to criteria

    Quote Originally Posted by HaroonSid View Post
    hi,
    i want to fill all dates of a month in range A4:A35

    while Month = range("A2").value
    and
    Year = range("A3").value
    Please Login or Register  to view this content.

  7. #7
    Forum Guru Sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,489

    Re: Fill all date of a month according to criteria

    @ jindon

    Flawless designer code as always. Do you feel like helping me with my code to allow for Month name and not Month No.
    Works if A2 = month No and not month name

  8. #8
    Forum Guru Sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,489

    Re: Fill all date of a month according to criteria

    thank you
    its working
    pleasure, Glad I could help. Thanks for rep point

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Choose Latest Date and Number of Month Criteria for Future Date
    By ShakJames in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 02-07-2017, 12:31 PM
  2. Week to Date / Month to Date with Multiple Criteria
    By marcojhb in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 08-31-2016, 01:51 PM
  3. [SOLVED] Formula to fill month end dates from start date to end date
    By Barieq in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 04-03-2016, 11:51 AM
  4. Fill Data -- Month and Date
    By beneesetas14 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 03-03-2014, 03:00 AM
  5. Replies: 2
    Last Post: 02-04-2013, 05:48 PM
  6. Date auto fill for a month
    By KellyPSmith in forum Excel General
    Replies: 5
    Last Post: 08-06-2008, 12:14 PM
  7. Date to fill and stay same - also to calculate 1 month
    By tstorzuk in forum Excel General
    Replies: 11
    Last Post: 07-17-2008, 02:10 PM

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