From: harshal on
Hi,
I am trying to launch an exe file using the API CeAppRunAtTime. I am facing
a problem that the exe launches immediately when the API is called instead at
the time that is being passed.
Even if i give pass the time 5 mins after the current time, the exe is
launched as soon as the the API is called.
I am using the following code,

const __int64 nano100SecInWeek=(__int64)10000000*60*60*24*7;
const __int64 nano100SecInDay=(__int64)10000000*60*60*24;
const __int64 nano100SecInHour=(__int64)10000000*60*60;
const __int64 nano100SecInMin=(__int64)10000000*60;
const __int64 nano100SecInSec=(__int64)10000000;

SYSTEMTIME SystemTime = {0};
GetSystemTime(&SystemTime );
SystemTime.wMinute = SystemTime.wMinute + (nano100SecInMin * 5);
int ret = CeRunAppAtTime(_T("\\Program Files\\MyApp.exe"),&SystemTime );

Can anyone please suggest what am i missing.
Thanks in advance,
Harshal.