Click here to Skip to main content
15,908,776 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: How do you structure your code/development environment ? Pin
Stuart Dootson14-Dec-08 7:43
professionalStuart Dootson14-Dec-08 7:43 
AnswerRe: How do you structure your code/development environment ? Pin
Jijo.Raj14-Dec-08 6:47
Jijo.Raj14-Dec-08 6:47 
QuestionSetWaitableTimer confusions Pin
George_George14-Dec-08 1:40
George_George14-Dec-08 1:40 
AnswerRe: SetWaitableTimer confusions Pin
Stuart Dootson14-Dec-08 6:25
professionalStuart Dootson14-Dec-08 6:25 
GeneralRe: SetWaitableTimer confusions Pin
George_George14-Dec-08 20:14
George_George14-Dec-08 20:14 
GeneralRe: SetWaitableTimer confusions Pin
Stuart Dootson14-Dec-08 21:19
professionalStuart Dootson14-Dec-08 21:19 
GeneralRe: SetWaitableTimer confusions Pin
George_George15-Dec-08 0:42
George_George15-Dec-08 0:42 
AnswerRe: SetWaitableTimer confusions Pin
Jijo.Raj14-Dec-08 6:37
Jijo.Raj14-Dec-08 6:37 
George_George wrote:
1. For API SetWaitableTimer, what are the meaning and function of parameters

pDueTime and lPeriod?

http://msdn.microsoft.com/en-us/library/ms686289.aspx


pDueTime - means exactly at which point of time, the timer should trigger first. If the value is positive, then it will be considered as absolute time else considered as relative time. Well, from your question it seems you're confused with absolute and relative time? isn't it? I'll explain a bit.

Absolute time - Assume you want to trigger the timer on New Year! In that case your timer should trigger on 1-Jan-2009 0:01 AM. So you can convert that time into a FILETIME value by using the function SystemTimeToFileTime()[^]and specify it as pDueTime and your timer will be signed exactly at that point.

Relative time - Just think about snoozing your outlook reminder for 10 minutes. That means - from NOW to 10 minutes. So you can specify the 10 minutes duration with negative sign. So the timer will be triggered exactly after 10 minutes.

As it says one is absolute - which means you exactly know the point of time and another is relative - means the value you specify is the duration of time from NOW, when the timer is to be signaled.

lPeriod - Assume after setting the timer at Midnight newyear, you want it to signal again in interval of 5 minutes - to wake up from bed Wink | ;) . In that case set this parameter as 5 minutes in milliseconds. Literally, it means the duration for trigger the same timer in periodic fashon, After it signalled for the first time. If you specify this param, then after first signalling, it will signal periodically by the specified time duration.

Phewww!!! I admit that it was a bit long. Hope it will be helpful to you.

Regards,
Jijo.

_____________________________________________________

http://weseetips.com[^] Visual C++ tips and tricks. Updated daily.

GeneralRe: SetWaitableTimer confusions Pin
George_George14-Dec-08 20:20
George_George14-Dec-08 20:20 
QuestionQuery XML in SQL 2005 using ADO in native C++ Pin
Green Fuze13-Dec-08 12:42
Green Fuze13-Dec-08 12:42 
Question[Message Deleted] Pin
chokahn13-Dec-08 3:50
chokahn13-Dec-08 3:50 
AnswerRe: reading bitmap pixel by pixel?? Pin
Jijo.Raj13-Dec-08 3:56
Jijo.Raj13-Dec-08 3:56 
AnswerRe: [Message Deleted] Pin
Jijo.Raj13-Dec-08 4:57
Jijo.Raj13-Dec-08 4:57 
QuestionCreating DialogBar in VC 2008 Pin
sabapathy_8013-Dec-08 3:13
sabapathy_8013-Dec-08 3:13 
QuestionHamming error check and correct Pin
King Tran13-Dec-08 2:40
King Tran13-Dec-08 2:40 
AnswerRe: Hamming error check and correct Pin
Stuart Dootson13-Dec-08 9:24
professionalStuart Dootson13-Dec-08 9:24 
GeneralRe: Hamming error check and correct Pin
Richard Andrew x6413-Dec-08 10:33
professionalRichard Andrew x6413-Dec-08 10:33 
QuestionQuestion regarding Visual C++ redistributable Pin
Zerox MXI13-Dec-08 2:26
Zerox MXI13-Dec-08 2:26 
AnswerRe: Question regarding Visual C++ redistributable Pin
Stuart Dootson13-Dec-08 9:31
professionalStuart Dootson13-Dec-08 9:31 
QuestionShall we change button style of messagebox? Pin
Le@rner13-Dec-08 0:37
Le@rner13-Dec-08 0:37 
AnswerRe: Shall we change button style of messagebox? Pin
Dr. Emmett Brown13-Dec-08 1:17
Dr. Emmett Brown13-Dec-08 1:17 
GeneralRe: Shall we change button style of messagebox? Pin
Le@rner13-Dec-08 1:37
Le@rner13-Dec-08 1:37 
AnswerRe: Shall we change button style of messagebox? Pin
Eytukan13-Dec-08 1:37
Eytukan13-Dec-08 1:37 
Questionsystem information Pin
zon_cpp13-Dec-08 0:05
zon_cpp13-Dec-08 0:05 
AnswerRe: system information Pin
Le@rner13-Dec-08 1:11
Le@rner13-Dec-08 1:11 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.