Try this function -- VarDateFromStr
How to get double from date?
![](https://techprofile.blob.core.windows.net/images/mTRjBkXqiU2SgoIJJ1L84Q.png?8D8BC5)
DangDKhanh-2637
946
Reputation points
Hi,
I have the following numbers:
int d=21, m=1, y=2022, h=0,m=0,s=0
I can convert them to string with format as datetime "2022/1/21 00:00:00", then convert to double by code from this post
but this result=1642698000 is different from excel 44582.
Can I achieve this without MFC?
Thanks you.