Click here to Skip to main content
15,868,164 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionRe: How can i calculate seconds value here? Pin
pasztorpisti15-Aug-12 22:18
pasztorpisti15-Aug-12 22:18 
AnswerRe: How can i calculate seconds value here? Pin
Le@rner15-Aug-12 22:25
Le@rner15-Aug-12 22:25 
SuggestionRe: How can i calculate seconds value here? Pin
pasztorpisti15-Aug-12 22:32
pasztorpisti15-Aug-12 22:32 
AnswerRe: How can i calculate seconds value here? Pin
Jochen Arndt16-Aug-12 1:43
professionalJochen Arndt16-Aug-12 1:43 
GeneralRe: How can i calculate seconds value here? Pin
pasztorpisti16-Aug-12 1:52
pasztorpisti16-Aug-12 1:52 
AnswerRe: How can i calculate seconds value here? Pin
Richard MacCutchan15-Aug-12 22:23
mveRichard MacCutchan15-Aug-12 22:23 
AnswerRe: How can i calculate seconds value here? Pin
pasztorpisti15-Aug-12 22:38
pasztorpisti15-Aug-12 22:38 
AnswerRe: How can i calculate seconds value here? Pin
Jochen Arndt15-Aug-12 22:49
professionalJochen Arndt15-Aug-12 22:49 
You can create a struct or union to define the bit assignments:
C++
typedef union _MyTime_t {
    WORD tm;
    struct {
        unsigned sec : 5; // 2 seconds resolution
        unsigned min : 6;
        unsigned hour : 5;
    } bits;
} MyTime_t;
MyTime_t tm;
tm.tm = 23939;
printf("%02u:%02u:%02u\n", tm.bits.hour, tm.bits.min, tm.bits.sec * 2);

GeneralRe: How can i calculate seconds value here? Pin
Le@rner15-Aug-12 23:27
Le@rner15-Aug-12 23:27 
QuestionI want to find out where the focus belongs after EN_KILLFOCUS? Pin
Falconapollo15-Aug-12 18:24
Falconapollo15-Aug-12 18:24 
AnswerRe: I want to find out where the focus belongs after EN_KILLFOCUS? Pin
Software_Developer15-Aug-12 19:26
Software_Developer15-Aug-12 19:26 
GeneralRe: I want to find out where the focus belongs after EN_KILLFOCUS? Pin
Falconapollo15-Aug-12 20:32
Falconapollo15-Aug-12 20:32 
QuestionDisabling Windows ShortCut Keys Pin
Don Guy14-Aug-12 13:42
Don Guy14-Aug-12 13:42 
AnswerRe: Disabling Windows ShortCut Keys Pin
Albert Holguin14-Aug-12 14:17
professionalAlbert Holguin14-Aug-12 14:17 
AnswerRe: Disabling Windows ShortCut Keys Pin
«_Superman_»14-Aug-12 17:39
professional«_Superman_»14-Aug-12 17:39 
AnswerRe: Disabling Windows ShortCut Keys Pin
Software_Developer14-Aug-12 21:02
Software_Developer14-Aug-12 21:02 
AnswerRe: Disabling Windows ShortCut Keys Pin
pasztorpisti14-Aug-12 21:08
pasztorpisti14-Aug-12 21:08 
AnswerRe: Disabling Windows ShortCut Keys Pin
Joan M14-Aug-12 23:25
professionalJoan M14-Aug-12 23:25 
QuestionAccessing Pixels with CreateDIBSection Pin
Member 925534913-Aug-12 20:38
Member 925534913-Aug-12 20:38 
AnswerRe: Accessing Pixels with CreateDIBSection Pin
Eugen Podsypalnikov13-Aug-12 21:05
Eugen Podsypalnikov13-Aug-12 21:05 
GeneralRe: Accessing Pixels with CreateDIBSection Pin
Member 925534913-Aug-12 22:23
Member 925534913-Aug-12 22:23 
AnswerRe: Accessing Pixels with CreateDIBSection Pin
pasztorpisti13-Aug-12 22:54
pasztorpisti13-Aug-12 22:54 
GeneralRe: Accessing Pixels with CreateDIBSection Pin
Member 925534914-Aug-12 7:58
Member 925534914-Aug-12 7:58 
GeneralRe: Accessing Pixels with CreateDIBSection Pin
pasztorpisti14-Aug-12 8:09
pasztorpisti14-Aug-12 8:09 
QuestionSpeed up a numerical Calculation. Circular Queue Pin
whitbuzben1813-Aug-12 7:55
whitbuzben1813-Aug-12 7:55 

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.