The MASM Forum Archive 2004 to 2012

General Forums => The Campus => Topic started by: d0d0 on July 04, 2009, 04:29:06 PM

Title: Date Time Picker
Post by: d0d0 on July 04, 2009, 04:29:06 PM
Howdy folks,

What would be the best way to retrieve time changes  when handling a DTN_DATETIMECHANGE notification from the DTP control?

1. Check for DTN_DATETIMECHANGE then retrieve the time from NMDATETIMECHANGE structure
2. Check for DTN_DATETIMECHANGE then SendMessage with DTM_GETSYSTEMTIME
3. Any other way?

Mucho gracias!
Title: Re: Date Time Picker
Post by: ToutEnMasm on July 04, 2009, 05:43:25 PM
You have it , Why search to get one another ?
Quote
typedef struct tagNMDATETIMECHANGE {
    NMHDR nmhdr;
    DWORD dwFlags;
    SYSTEMTIME st;
} NMDATETIMECHANGE, *LPNMDATETIMECHANGE;
Title: Re: Date Time Picker
Post by: d0d0 on July 04, 2009, 07:03:04 PM
Hi TouteEnMasm

I'm trying to find out which method people generally use
Title: Re: Date Time Picker
Post by: Tedd on July 05, 2009, 04:45:38 PM
The first one - you're already GIVEN the time, there's no need to then go and ask for it again.


Man: Excuse me miss, would you know the correct time?
Woman: Yes, it's 1:32pm
Man: So what time is?
Woman: ...1:32pm...?
Title: Re: Date Time Picker
Post by: dedndave on July 05, 2009, 04:48:29 PM
at least she gives you the time of day - lol
she would prolly tell me "time for you to ask someone esle"

Quote1. Check for DTN_DATETIMECHANGE then retrieve the time from NMDATETIMECHANGE structure
2. Check for DTN_DATETIMECHANGE then SendMessage with DTM_GETSYSTEMTIME
3. Any other way?

i don't think d0d0 was intending to perform theses as steps in a sequence
rather, he was listing the different possible ways of achieving the goal