ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   date serial (https://www.excelbanter.com/excel-programming/361670-date-serial.html)

Striker

date serial
 
How do I get today's date as a serial into a variable?

dim dDate as Date
dDate = serial NOW()

Of course the above does not work.



AA2e72E

date serial
 
try:

Sub aa()
Dim serdate As Long
serdate = DateValue(Now)
End Sub


Dave Peterson

date serial
 

dim lDate as long
ldate = clng(date)



Striker wrote:

How do I get today's date as a serial into a variable?

dim dDate as Date
dDate = serial NOW()

Of course the above does not work.


--

Dave Peterson


All times are GMT +1. The time now is 06:16 AM.

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