Click here to Skip to main content
15,888,610 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: DialogBox 64bit ? Pin
Richard MacCutchan26-Sep-12 2:42
mveRichard MacCutchan26-Sep-12 2:42 
QuestionRe: DialogBox 64bit ? Pin
CPallini26-Sep-12 3:40
mveCPallini26-Sep-12 3:40 
AnswerRe: DialogBox 64bit ? Pin
Smart Arab26-Sep-12 5:01
Smart Arab26-Sep-12 5:01 
GeneralRe: DialogBox 64bit ? Pin
Richard MacCutchan26-Sep-12 5:12
mveRichard MacCutchan26-Sep-12 5:12 
GeneralRe: DialogBox 64bit ? Pin
Smart Arab26-Sep-12 5:54
Smart Arab26-Sep-12 5:54 
GeneralRe: DialogBox 64bit ? Pin
Jochen Arndt26-Sep-12 6:10
professionalJochen Arndt26-Sep-12 6:10 
GeneralRe: DialogBox 64bit ? Pin
Smart Arab26-Sep-12 22:45
Smart Arab26-Sep-12 22:45 
GeneralRe: DialogBox 64bit ? Pin
Richard MacCutchan26-Sep-12 6:29
mveRichard MacCutchan26-Sep-12 6:29 
Smart Arab wrote:
DialogProc function Return INT_PTR while the WinMain which return the DialogProc "must return int."
What do you mean, these are two different functions?
Smart Arab wrote:
I think I must find a way to convert from IntPtr to int safely ..
No, you just need to follow the information provided by the documentation, as I suggested before, and use a cast to satisfy the compiler thus:
C++
// in WinMain
return DialogBox(hInstance, MAKEINTRESOURCE(DLG_MAIN), NULL, (DLGPROC)DialogProc);

One of these days I'm going to think of a really clever signature.

GeneralRe: DialogBox 64bit ? Pin
Smart Arab26-Sep-12 22:42
Smart Arab26-Sep-12 22:42 
GeneralRe: DialogBox 64bit ? Pin
CPallini26-Sep-12 11:47
mveCPallini26-Sep-12 11:47 
GeneralRe: DialogBox 64bit ? Pin
Smart Arab26-Sep-12 22:39
Smart Arab26-Sep-12 22:39 
GeneralRe: DialogBox 64bit ? Pin
CPallini26-Sep-12 22:45
mveCPallini26-Sep-12 22:45 
QuestionHow to make slider movement smooth in MFC.? Pin
mbatra3125-Sep-12 20:39
mbatra3125-Sep-12 20:39 
QuestionRandom Number Pin
pix_programmer25-Sep-12 20:05
pix_programmer25-Sep-12 20:05 
AnswerRe: Random Number Pin
Ingo25-Sep-12 20:38
Ingo25-Sep-12 20:38 
AnswerRe: Random Number Pin
CPallini25-Sep-12 22:25
mveCPallini25-Sep-12 22:25 
AnswerRe: Random Number Pin
Ingo25-Sep-12 23:55
Ingo25-Sep-12 23:55 
GeneralRe: Random Number Pin
CPallini26-Sep-12 0:28
mveCPallini26-Sep-12 0:28 
GeneralRe: Random Number Pin
Ingo26-Sep-12 0:35
Ingo26-Sep-12 0:35 
AnswerRe: Random Number Pin
_AnsHUMAN_ 26-Sep-12 0:12
_AnsHUMAN_ 26-Sep-12 0:12 
AnswerRe: Random Number Pin
Software_Developer26-Sep-12 8:00
Software_Developer26-Sep-12 8:00 
AnswerOT Just curious... Pin
jeron126-Sep-12 8:21
jeron126-Sep-12 8:21 
QuestionRe: OT Just curious... Pin
David Crow26-Sep-12 10:52
David Crow26-Sep-12 10:52 
AnswerRe: OT Just curious... Pin
CPallini26-Sep-12 10:55
mveCPallini26-Sep-12 10:55 
GeneralRe: OT Just curious... Pin
jeron126-Sep-12 11:02
jeron126-Sep-12 11:02 

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.