Help Please

root2007

New member
Local time
Today, 07:34
Joined
Jan 25, 2012
Messages
9
Hi everyone,

Can you please help me on how to get the number of days per month? What is the VB syntax for it? Thanks and more power!
 
u mean like Jan >> 31 days , Feb >> 29/28 days ??
if u mean like that u can use this
First Day of The month : DateSerial(Year(Now), Month(Now), 1)
Last Day of The Month : DateSerial(Year(Now), Month(Now) + 1, 0)
So number of the day : Last Day - First Day +1
 
If you simply what to know how many days in the current month use;
Code:
=Format(DateSerial(Year(Date()),Month(Date())+1,0),"DD")
 
Thank to for your help and thank you for the info you gave me about posting. More power!
 

Users who are viewing this thread

Back
Top Bottom