15 мая 2023 года "Исходники.РУ" отмечают своё 23-летие!
Поздравляем всех причастных и неравнодушных с этим событием!
И огромное спасибо всем, кто был и остаётся с нами все эти годы!

Главная Форум Журнал Wiki DRKB Discuz!ML Помощь проекту


MFC Ctime::GetCurrentTime

Serge Potteck -- serge@lune.cst.cnes.fr
Tuesday, August 13, 1996


would you please know a reason, why CTime::GetCurrentTime 
gives me an incorrect date, around 1970, and quickly 
increasing between two calls ?

Environment : Visual C++ 1.51, Windows 3.1, same behaviour on two compacq

Thanks a lot

Serge Potteck, France




Mario Contestabile -- Mario_Contestabile.UOS__MTL@UOSMTL2.universal.com
Thursday, August 15, 1996

[Mini-digest: 2 responses]

>would you please know a reason, why CTime::GetCurrentTime 
>gives me an incorrect date, around 1970, and quickly 
>increasing between two calls ?

Check that you are calling CTime::GetCurrentTime() and
*not* ::GetCurrentTime() which would return the same thing as GetTickCount(),
which would explain the "quickly increasing" behavior.

mcontest@universal.com

-----From: "Jeff Shanholtz" 

I just experienced a similar problem. Are you calling it like this: 
"CTime::GetCurrentTime" or are you just calling "GetCurrentTime"? If you don't 
use the CTime specifier, the API function gets called, which is very different 
from the MFC function; it returns the number of milliseconds (or something 
like that) since Windows has started.

Good luck.

Jeff Shanholtz
jshanholtz@msn.com




| Вернуться в корень Архива |