+ Reply to Thread
Results 1 to 8 of 8

Tying a monthly calenda to one cell

  1. #1
    Registered User
    Join Date
    10-18-2022
    Location
    Germany
    MS-Off Ver
    365
    Posts
    10

    Tying a monthly calenda to one cell

    Hello to everyone reading this thread

    I was wondering if it's possible to tie a calendar to one cell.

    Say for instance: A1 is 2023

    From A2 till Z2 are dates (A2 is the 01.01.2023 and Z2 is 26.01.2023)

    Is it possible for the calendar to change just by changing the year in A1?
    Like i type 2024 and then all dates from A2 to Z2 change accordingly.

    Thank you very much!

    I would highly appreciate it

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: Tying a monthly calenda to one cell

    Yes.

    In A2, enter =A1+1
    Copy that across as needed

    Format as date
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  3. #3
    Registered User
    Join Date
    10-18-2022
    Location
    Germany
    MS-Off Ver
    365
    Posts
    10

    Re: Tying a monthly calenda to one cell

    Thank you for your answer!
    But when i do that i end up with 2024 in A2.
    My wish is to change A1 which is the year and the rest will automatically change.

  4. #4
    Forum Expert avk's Avatar
    Join Date
    07-12-2007
    Location
    India
    MS-Off Ver
    Microsoft Office 2013
    Posts
    3,223

    Re: Tying a monthly calenda to one cell

    If you go with google search engine, lot of template available. Here i have attach one same file for your reference.
    Attached Files Attached Files


    atul


    If my answer (or that of other members) has helped you, please say "Thanks" by clicking the Add Reputation button at the foot of one of their posts.

    Also: if your problem is solved, please take the time to mark your thread as SOLVED by going to the top of your first post, selecting "Thread Tools" and then "Mark thread as solved".

  5. #5
    Registered User
    Join Date
    10-18-2022
    Location
    Germany
    MS-Off Ver
    365
    Posts
    10

    Re: Tying a monthly calenda to one cell

    Thank you so much!
    This is what i want (i mean the idea of it).
    But still can't apply it.
    I have attached a file here, and what i wanna achieve is make the cells from F8 to M8 tied to E5.
    so that when i change E5 to 2024 all of the cells change as well.
    In the excel file attached, the dates where typed manually.
    Last question maybe, how can i highlight the weekends (sat-sun) and the holidays (found on the second sheet) in grey? -the idea is to highlight all the vertical cells under the weekend or holiday.
    i would greatly appreciate the help
    Thanks a lot!
    Attached Files Attached Files

  6. #6
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: Tying a monthly calenda to one cell

    Instead of just 2024, enter 1/1/2024, then format to just show year. I thought you had a full date in A1

  7. #7
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,705

    Re: Tying a monthly calenda to one cell

    Use this formula in F8:

    =DATE(E5,1,1)

    and this one in G8:

    =F8+1

    Then you can copy G8 across as far as you need to.

    To highlight weekends, you can use this formula:

    =WEEKDAY(F$8,2)>5

    in a Conditional Formatting rule, i.e. select all the cells that you want this to apply to (e.g. from F8 across and down), then click on Conditional Formatting | New Rule | Use a formula... , then put that formula in the box which pops up and click on the Format button | Fill tab and choose your colour, then OK twice to exit the dialogue box.

    Hope this helps.

    Pete

  8. #8
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,705

    Re: Tying a monthly calenda to one cell

    If you want to show holidays in the same colour as the weekends, you can amend the CF formula to this:

    =OR(WEEKDAY(F$8,2)>5,COUNTIF(Holidays!$B:$B,F$8))

    Hope this helps.

    Pete

+ 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. Question tying not to use .select
    By Xlnovice1 in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 10-06-2020, 04:40 PM
  2. [SOLVED] Tying two cells together so they are MUTUALLY dependent
    By lesoies in forum Excel General
    Replies: 11
    Last Post: 09-10-2012, 01:16 PM
  3. [SOLVED] Ideas for a birthday calenda
    By moley165 in forum Excel General
    Replies: 6
    Last Post: 05-04-2012, 12:10 PM
  4. Replies: 4
    Last Post: 02-14-2012, 04:56 PM
  5. Excel 2007 : help tying cells together
    By mswain1 in forum Excel General
    Replies: 3
    Last Post: 05-20-2009, 03:39 PM
  6. Tying Two Documents Together
    By swiftbmx in forum Excel General
    Replies: 1
    Last Post: 04-03-2007, 11:54 AM
  7. [SOLVED] Tying an imported graphic to a cell
    By T.R. Young in forum Excel General
    Replies: 0
    Last Post: 10-05-2005, 04:05 PM

Tags for this Thread

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