Click here to Skip to main content
15,895,423 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Subclassing a CListCtrl derived class in CDialog Pin
Atlantys22-Oct-03 11:19
Atlantys22-Oct-03 11:19 
GeneralRe: Subclassing a CListCtrl derived class in CDialog Pin
b_girl23-Oct-03 3:20
b_girl23-Oct-03 3:20 
Generalanother question about command.com Pin
includeh1022-Oct-03 8:23
includeh1022-Oct-03 8:23 
Generalc++ and c# in .NET Pin
HudsonKane22-Oct-03 7:56
HudsonKane22-Oct-03 7:56 
GeneralRe: c++ and c# in .NET Pin
Ryan_Roberts22-Oct-03 11:55
Ryan_Roberts22-Oct-03 11:55 
GeneralRe: c++ and c# in .NET Pin
HudsonKane23-Oct-03 10:09
HudsonKane23-Oct-03 10:09 
GeneralUpdating a list box w/ progress data Pin
jimNLX22-Oct-03 7:30
jimNLX22-Oct-03 7:30 
GeneralRe: Updating a list box w/ progress data Pin
David Crow22-Oct-03 7:43
David Crow22-Oct-03 7:43 
Your "processing" loop is not yielding enough CPU time such that the WM_PAINT messages can be processed. In other words, you've got something like:

while (some_condition)
{
    do some processing
    update listbox
}
 
// not until this point do the items appear in the listbox


This is a prime candidate for a UI thread (i.e., thread with message pump). In your app's primary thread will be the listbox. When processing starts, create another thread to handle the processing. That thread will post (not send) messages back to the primary thread with items to be added to the listbox.

Check out these articles:

http://flounder.com/uithreads.htm
http://flounder.com/workerthreads.htm


Five birds are sitting on a fence.
Three of them decide to fly off.
How many are left?

QuestionHow to open a notepad file in a edit box Pin
Deepak Samuel22-Oct-03 6:05
Deepak Samuel22-Oct-03 6:05 
AnswerRe: How to open a notepad file in a edit box Pin
David Crow22-Oct-03 7:52
David Crow22-Oct-03 7:52 
GeneralRe: How to open a notepad file in a edit box Pin
Deepak Samuel22-Oct-03 8:42
Deepak Samuel22-Oct-03 8:42 
GeneralRe: How to open a notepad file in a edit box Pin
David Crow22-Oct-03 8:48
David Crow22-Oct-03 8:48 
GeneralRe: How to open a notepad file in a edit box Pin
Atlantys22-Oct-03 11:30
Atlantys22-Oct-03 11:30 
GeneralProblem with editbox Pin
Deepak Samuel22-Oct-03 6:03
Deepak Samuel22-Oct-03 6:03 
GeneralRe: Problem with editbox Pin
Ravi Bhavnani22-Oct-03 6:12
professionalRavi Bhavnani22-Oct-03 6:12 
GeneralRe: Problem with editbox Pin
David Crow22-Oct-03 7:54
David Crow22-Oct-03 7:54 
GeneralQUESTION about bitwise shift operations Pin
va_dev22-Oct-03 5:49
va_dev22-Oct-03 5:49 
GeneralRe: QUESTION about bitwise shift operations Pin
David Crow22-Oct-03 8:05
David Crow22-Oct-03 8:05 
GeneralRe: QUESTION about bitwise shift operations Pin
va_dev22-Oct-03 19:55
va_dev22-Oct-03 19:55 
GeneralRe: QUESTION about bitwise shift operations Pin
David Crow23-Oct-03 3:15
David Crow23-Oct-03 3:15 
GeneralRe: QUESTION about bitwise shift operations Pin
va_dev23-Oct-03 4:53
va_dev23-Oct-03 4:53 
GeneralRe: QUESTION about bitwise shift operations Pin
David Crow23-Oct-03 6:49
David Crow23-Oct-03 6:49 
Generalapply local-time-zone/dst on a DBTIMESTAMP variable Pin
ohadp22-Oct-03 5:35
ohadp22-Oct-03 5:35 
GeneralUse of the Keyboard's events Pin
DiakRufus22-Oct-03 4:54
DiakRufus22-Oct-03 4:54 
GeneralRe: Use of the Keyboard's events Pin
G. Steudtel22-Oct-03 5:22
G. Steudtel22-Oct-03 5:22 

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.