I will have a Date that is read from a file in VBA. What I need to place in (2) new variables will be the following month's beginning date and ending date.
The Variables in use:
'aDate' = Known Date (this can any day within a given month)
'bDate' = Calculated 1st date of the following month.
'cDate' = Calculated Last date of the following month.
Example:
What I've come up with is goofy and I know there's got to be a better way. I need the solution to be in VBA code rather than using Excel formulas. Thanks!
The Variables in use:
'aDate' = Known Date (this can any day within a given month)
'bDate' = Calculated 1st date of the following month.
'cDate' = Calculated Last date of the following month.
Example:
Code:
Given:
'aDate' = 09/21/11
Results:
'bDate' = 10/01/11
'cDate' = 10/31/11
What I've come up with is goofy and I know there's got to be a better way. I need the solution to be in VBA code rather than using Excel formulas. Thanks!