+ Reply to Thread
Results 1 to 7 of 7

Auto Populate quarters by just typing in the number of years

  1. #1
    Registered User
    Join Date
    01-15-2010
    Location
    London
    MS-Off Ver
    Excel 2013
    Posts
    5

    Question Auto Populate quarters by just typing in the number of years

    Hi Folks,

    I'm struggling with this one! I need a formula that can automatically populate yearly quarters in separate columns based on a number of years.
    So if I put in 5 years - excel would populate 20 columns with Quarter 1 - Quarter 2 and so on. If I then change it to 3 years it would only populate 12 columns.

    Is there a way to do this somehow?

    Thank you so much!

  2. #2
    Valued Forum Contributor
    Join Date
    09-21-2011
    Location
    Birmingham UK
    MS-Off Ver
    Excel 2003/7/10
    Posts
    2,188

    Re: Auto Populate quarters by just typing in the number of years

    I think you'll need the formulas there, dependant on an IF, whether they show.

    So you'd have

    =if(a1=1,"Q1 Yr 1","")
    =if(a1=1,"Q2 Yr 1","")
    =if(a1=1,"Q3 Yr 1","")
    =if(a1=1,"Q4 Yr 1","")
    =if(a1=2,"Q1 Yr 2","")
    =if(a1=2,"Q2 Yr 2","")
    =if(a1=2,"Q3 Yr 2","")
    =if(a1=2,"Q4 Yr 2","")

    etc.
    Hope this helps

    Sometimes its best to start at the beginning and learn VBA & Excel.

    Please dont ask me to do your work for you, I learnt from Reading books, Recording, F1 and Google and like having all of this knowledge in my head for the next time i wish to do it, or wish to tweak it.
    Available for remote consultancy work PM me

  3. #3
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,648

    Re: Auto Populate quarters by just typing in the number of years

    Assuming you input no. of years in A2, then
    In B2
    Please Login or Register  to view this content.
    and copy down.

    Is this what you are trying to achieve?
    Attached Files Attached Files
    Regards
    sktneer


    Treat people the way you want to be treated. Talk to people the way you want to be talked to.
    Respect is earned NOT given.

  4. #4
    Registered User
    Join Date
    01-15-2010
    Location
    London
    MS-Off Ver
    Excel 2013
    Posts
    5

    Re: Auto Populate quarters by just typing in the number of years

    Quote Originally Posted by sktneer View Post
    Assuming you input no. of years in A2, then
    In B2
    Please Login or Register  to view this content.
    and copy down.

    Is this what you are trying to achieve?
    Yes thank you! I would now just like to be able to put them 1 quarter in each column instead of in one columns with a quarter in each row. Is this possible somehow?

    And each quarter shouldn't come out as "Quarter 1" but Jul-14 then Oct-14 then Jan 15... etc. Does this make sense?

    Thank you again!
    Last edited by sugar_lips; 08-21-2014 at 10:36 AM.

  5. #5
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Auto Populate quarters by just typing in the number of years

    Try it like this:

    Entered in B2 and copied across until you get blanks.

    =IF(COLUMNS($B2:B2)<=$A2*4,"Quarter "&COLUMNS($B2:B2),"")
    Biff
    Microsoft MVP Excel
    Keep It Simple Stupid

    Let's Go Pens. We Want The Cup.

  6. #6
    Registered User
    Join Date
    01-15-2010
    Location
    London
    MS-Off Ver
    Excel 2013
    Posts
    5

    Re: Auto Populate quarters by just typing in the number of years

    Quote Originally Posted by Tony Valko View Post
    Try it like this:

    Entered in B2 and copied across until you get blanks.

    =IF(COLUMNS($B2:B2)<=$A2*4,"Quarter "&COLUMNS($B2:B2),"")
    this worked thank you!!! Now for the last step.

    Is it possible for the "Quarter1" to come out as a date like Jul-14 then Quarter 2 to come out as Oct-14? Thank you so much for all the help already!

  7. #7
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    2016
    Posts
    14,675

    Re: Auto Populate quarters by just typing in the number of years

    Try putting the first date in B2 and then this version of Tony's formula in C2 copied across

    =IF(COLUMNS($B2:C2)<=$A2*4,EDATE(B2,COLUMNS($C2:C2)*3),"")

    custom format all dates as mmm-yy
    Audere est facere

+ 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] Auto populate dates to figure in for leap years
    By SethS in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 08-08-2014, 06:49 AM
  2. Auto fill a cell with a colour when typing a number
    By Anuru in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 07-03-2014, 11:18 AM
  3. [SOLVED] Excel 2010 - Time between dates in years and quarters (.25)
    By undergrads in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 12-18-2013, 02:16 AM
  4. [SOLVED] Can I auto fill a cell in one worksheet by typing a code number
    By Gomer Pyle in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-06-2005, 03:05 PM
  5. Show quarters and years on x axis of a chart
    By Kacee in forum Excel Charting & Pivots
    Replies: 3
    Last Post: 03-19-2005, 12:06 AM

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