By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,984 Members | 1,461 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,984 IT Pros & Developers. It's quick & easy.

thread message to a dialog box

P: 68
I have a message that comes from a seperate thread of execution that I want to impact a dialog box already on the screen.

The dialog box is modal but I believe it would not make any difference if it was modal or modeless.

The program is an SDI and so it it not as easy as it would be if the program was a dialog based program. Instead, the dialog box is created with a method of the program's view class and so it is only within the scope of that method.

So how could a seperate thread of execuation send a message to that dialog box?
Aug 7 '07 #1
Share this Question
Share on Google+
1 Reply

Expert Mod 5K+
P: 9,197
Give the thread a handle to the dialog. The thread argument is a void* so you can pass the address of any struct and thereby pass unlimited arguments to the thread.

Call an interlocked method on the dialog. You may need to write this.
Aug 7 '07 #2

Post your reply

Sign in to post your reply or Sign up for a free account.