|
-
Oct 26th, 2001, 08:47 AM
#7
I'm not sure. Also, I just found this in MSDN:
An application calls EndDialog from within the dialog box procedure; the function must not be used for any other purpose.
So I'm not sure if it's ok to call this function. I think
SendMessage(hDlg, WM_COMMAND, MAKELONG(IDOK, BN_CLICKED), GetDlgItem(hDlg, IDOK));
is still the cleanest solution. But I don't know how to emulate or access MAKELONG in VB. It basically combines two 16-bit values (integers in VB) to one 32-bit (long in VB).
Here is the C definition of MAKELONG, maybe you know how to convert it:
Code:
#define MAKELONG(a, b) ((LONG)(((WORD)(a)) | ((DWORD)((WORD)(b))) << 16))
long is 32 bit, word is 16 bit and dword is 32 bit.
All the buzzt
 CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|