Click here to Skip to main content
15,921,028 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: VK_TAB in an edit control in a dialog Pin
igor196016-Oct-03 7:50
igor196016-Oct-03 7:50 
GeneralRe: VK_TAB in an edit control in a dialog Pin
Dave_16-Oct-03 8:02
Dave_16-Oct-03 8:02 
GeneralSocket Programming : connecting to server Pin
Cyberizen16-Oct-03 5:02
Cyberizen16-Oct-03 5:02 
GeneralRe: Socket Programming : connecting to server Pin
script_smiths16-Oct-03 22:23
script_smiths16-Oct-03 22:23 
GeneralPrinting Landscape on Windows 2000 Pin
Jonathan Craig16-Oct-03 5:00
Jonathan Craig16-Oct-03 5:00 
GeneralRe: Printing Landscape on Windows 2000 Pin
Steve S16-Oct-03 5:26
Steve S16-Oct-03 5:26 
GeneralDaylight saving problems when using winapi's timezone functions. Pin
Patric_J16-Oct-03 4:56
Patric_J16-Oct-03 4:56 
GeneralRe: Daylight saving problems when using winapi's timezone functions. Pin
Patric_J20-Oct-03 7:40
Patric_J20-Oct-03 7:40 
Got the answer in another forum, here's the information if anyone else have similar problem:

Subject: Re: Daylight saving problems when using winapi's timezone functions.
From: "David A. Mair" Sent: 10/17/2003 1:02:16 PM


I have a simple SNTP client app where I need to do the same thing. My case
correctly handles daylight savings, here's the relevant section of code:

DWORD tzResult;<br />
TIME_ZONE_INFORMATION tzInfo;<br />
// Get time zone offset<br />
tzResult = GetTimeZoneInformation(&tzInfo);<br />
m_Bias = (int)tzInfo.Bias;<br />
switch(tzResult)<br />
{<br />
case TIME_ZONE_ID_STANDARD:<br />
    m_Bias += (int)tzInfo.StandardBias;<br />
    m_TZ = tzInfo.StandardName;<br />
    break;<br />
<br />
case TIME_ZONE_ID_DAYLIGHT:<br />
    m_Bias += (int)tzInfo.DaylightBias;<br />
    m_TZ = tzInfo.DaylightName;<br />
    break;<br />
<br />
case TIME_ZONE_ID_UNKNOWN:<br />
    break;<br />
<br />
default:<br />
    m_Bias = 0;<br />
}


m_Bias now holds the correct timezone offset from UTC in seconds for the
local time regardless of the time of year (assuming the computer has a
correctly configured clock and operating system). GetTimeZoneInformation()
is a Win32 function IIRC.
GeneralCShellFileOp Pin
Kevin Marren16-Oct-03 3:53
Kevin Marren16-Oct-03 3:53 
GeneralRe: CShellFileOp Pin
David Crow16-Oct-03 6:54
David Crow16-Oct-03 6:54 
GeneralFILE Pin
hph16-Oct-03 3:51
hph16-Oct-03 3:51 
GeneralRe: FILE Pin
David Crow16-Oct-03 6:57
David Crow16-Oct-03 6:57 
GeneralSoftware analysis tools Pin
Shay Harel16-Oct-03 3:42
Shay Harel16-Oct-03 3:42 
GeneralClistBox problem here........help!!!!! :-( Pin
Steve Obbayi16-Oct-03 3:31
professionalSteve Obbayi16-Oct-03 3:31 
GeneralRe: ClistBox problem here........help!!!!! :-( Pin
Rafael Fernández López16-Oct-03 9:39
Rafael Fernández López16-Oct-03 9:39 
GeneralRe: ClistBox problem here........help!!!!! :-( Pin
Mike Danberg16-Oct-03 10:01
Mike Danberg16-Oct-03 10:01 
GeneralRe: ClistBox problem here........help!!!!! :-( Pin
Steve Obbayi16-Oct-03 19:07
professionalSteve Obbayi16-Oct-03 19:07 
GeneralCComboBox Pin
De Nardis Andrea16-Oct-03 3:29
De Nardis Andrea16-Oct-03 3:29 
GeneralRe: CComboBox Pin
David Crow16-Oct-03 7:07
David Crow16-Oct-03 7:07 
GeneralRe: CComboBox Pin
De Nardis Andrea16-Oct-03 8:04
De Nardis Andrea16-Oct-03 8:04 
Generalbluetooth Pin
da_adel16-Oct-03 3:28
da_adel16-Oct-03 3:28 
Questionhow do i make a bitmap appear on a button when i click on the button Pin
swerajan16-Oct-03 2:51
swerajan16-Oct-03 2:51 
GeneralOwner Drawn CHeaderCtrl Items Pin
Uller16-Oct-03 1:58
Uller16-Oct-03 1:58 
GeneralRe: Owner Drawn CHeaderCtrl Items Pin
Roger Allen16-Oct-03 2:19
Roger Allen16-Oct-03 2:19 
GeneralRe: Owner Drawn CHeaderCtrl Items Pin
Uller16-Oct-03 3:39
Uller16-Oct-03 3:39 

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.