ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Is Date Odd or Even? (https://www.excelbanter.com/excel-programming/383409-date-odd-even.html)

CLR

Is Date Odd or Even?
 
Hi All.........
I am trying to create a macro that will test the DATE, and if it is an ODD
number, run Macro1, and if it is an EVEN number, run Macro2........

Can't seem to get there.......help please.

Vaya con Dios,
Chuck, CABGx3



Dave Peterson

Is Date Odd or Even?
 
Based on the day?

if day(date) mod 2 = 1 then
call OddMacro
else
call EvenMacro
end if



CLR wrote:

Hi All.........
I am trying to create a macro that will test the DATE, and if it is an ODD
number, run Macro1, and if it is an EVEN number, run Macro2........

Can't seem to get there.......help please.

Vaya con Dios,
Chuck, CABGx3


--

Dave Peterson

CLR

Is Date Odd or Even?
 
So cool it is.................thanks Dave

Vaya con Dios,
Chuck, CABGx3




"Dave Peterson" wrote:

Based on the day?

if day(date) mod 2 = 1 then
call OddMacro
else
call EvenMacro
end if



CLR wrote:

Hi All.........
I am trying to create a macro that will test the DATE, and if it is an ODD
number, run Macro1, and if it is an EVEN number, run Macro2........

Can't seem to get there.......help please.

Vaya con Dios,
Chuck, CABGx3


--

Dave Peterson



All times are GMT +1. The time now is 10:18 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com