PDA

View Full Version : Create a custom calendar between two dates



matt_mel96
08-26-2012, 05:17 PM
Hi All,

I am trying to automate a bidding process at work and as part of this process we generate a custom calendar between two dates. I have looked at various code (Microsoft KB 150774) to create a calendar however most seem to only generate a single month or year, whereas my tasks may traverse from one year to the next.

Basically, what I am trying to do is have the user enter a Start Date (Cell B1) and End Date (B2) and then click a button to generate the calendar in the cells below with the 1st week in Row 15 (I have some other data in between). Only formatting initially would be to commence the weeks on a Monday and use a standard date format of dd-Mmm-yy. I can then apply Conditional formatting to highlight my weekends and other dates I need to emphasis.

I am running Excel 2010 and whilst I have a bit of VBA experience, it is a bit rusty through non-use. Any assistance anybody can provide is greatly appreciated.

Bob Phillips
08-27-2012, 12:41 AM
The task is easy enough, but the coding comes in laying it out. You need to define and the calendar is laid out, just dates, just dates and empty input cells, one day per row, one week per row, 4 weeks per row, or what.