how does the UIThread and worker thread communicates and
handle events

Answers were Sorted based on User's Feedback



how does the UIThread and worker thread communicates and handle events..

Answer / vikram

UI thread and Worker thread can communicate with each other using SendMessage() or PostMessage().SendMessage() returns when the message is used by the Thread. PostMessage Returns immediately. These two method require Window handle of the UI Thread.

One can also use PostThreadMessage(thread id, message).here UI thread id is required.

Is This Answer Correct ?    0 Yes 0 No

how does the UIThread and worker thread communicates and handle events..

Answer / vishnu

Worker threads are used to process in back and can not
modify any user interface directly.
Ex: Used to calculate some complicated calculations.

UI threads can change user interface directly
Ex: Used to change UI display images in windows MFC
application

Is This Answer Correct ?    1 Yes 3 No

Post New Answer

More MFC Interview Questions

how to repaint when working with horizontal scroll bar

0 Answers  


How can update edit control data of an executing application from other application?

3 Answers   HP,


Types of DLL's

11 Answers   Invensys,


1)why we cant create more than one instance of the class Derived from CWinApp

5 Answers   Alstom,


Which Macro is a Super set of other two macro DECLARE_SERIAL,DECLARE_DYNAMIC and DECLARE_DYNCREATE. ?

2 Answers   Sony,






what is functioning of DIalodDataXchange ..?

0 Answers  


What is the base class for MFC Framework ?

2 Answers   Mphasis,


1) How do you Destroy a Dialog Box ?

2 Answers   Honeywell,


What is the difference between the SDI and MDI

3 Answers   Invensys,


What is a critical section and how is it implemented?

2 Answers  


what is the use of AFX_MANAGE_STATE ?

4 Answers   HCL,


1)How to load an icon on a button as Dynamically ?

1 Answers   HCL,


Categories