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

C / C++ / MFC

 
QuestionStrange CListBox Behavior Pin
wdolson7-Jan-16 14:44
wdolson7-Jan-16 14:44 
GeneralRe: Strange CListBox Behavior Pin
Richard MacCutchan7-Jan-16 22:07
mveRichard MacCutchan7-Jan-16 22:07 
GeneralRe: Strange CListBox Behavior Pin
Jochen Arndt7-Jan-16 22:18
professionalJochen Arndt7-Jan-16 22:18 
SuggestionRe: Strange CListBox Behavior Pin
Jochen Arndt7-Jan-16 22:17
professionalJochen Arndt7-Jan-16 22:17 
GeneralRe: Strange CListBox Behavior Pin
wdolson7-Jan-16 22:42
wdolson7-Jan-16 22:42 
GeneralRe: Strange CListBox Behavior Pin
Richard MacCutchan7-Jan-16 22:51
mveRichard MacCutchan7-Jan-16 22:51 
AnswerRe: Strange CListBox Behavior Pin
wdolson7-Jan-16 23:09
wdolson7-Jan-16 23:09 
GeneralRe: Strange CListBox Behavior Pin
Jochen Arndt7-Jan-16 23:11
professionalJochen Arndt7-Jan-16 23:11 
You may debug your application and inspect all list items (index, string, value); optionally also using TRACE statements.

But you should also show the code used to add items to the right list box because the source may be there (I guess that it is empty upon program start).

When the list box has sorting enabled, the order of items shown on screen does not correspond to the indexes. So when adding an item, it should look like:
int ndx = m_lstRight.AddString(strItem);
m_lstRight.SetItemData(ndx, val);

GeneralRe: Strange CListBox Behavior Pin
wdolson7-Jan-16 23:18
wdolson7-Jan-16 23:18 
GeneralRe: Strange CListBox Behavior Pin
Jochen Arndt7-Jan-16 23:26
professionalJochen Arndt7-Jan-16 23:26 
GeneralRe: Strange CListBox Behavior Pin
wdolson7-Jan-16 23:33
wdolson7-Jan-16 23:33 
GeneralRe: Strange CListBox Behavior Pin
Jochen Arndt7-Jan-16 23:42
professionalJochen Arndt7-Jan-16 23:42 
GeneralRe: Strange CListBox Behavior Pin
Richard MacCutchan8-Jan-16 1:04
mveRichard MacCutchan8-Jan-16 1:04 
QuestionEasy to use asymmetric (public key) encryption Pin
peterchen6-Jan-16 5:26
peterchen6-Jan-16 5:26 
QuestionHow to communicate between two different app using SendMessage API? Pin
Anasuya201529-Dec-15 19:56
Anasuya201529-Dec-15 19:56 
AnswerRe: How to communicate between two different app using SendMessage API? Pin
Richard MacCutchan29-Dec-15 22:29
mveRichard MacCutchan29-Dec-15 22:29 
GeneralRe: How to communicate between two different app using SendMessage API? Pin
Anasuya201530-Dec-15 2:32
Anasuya201530-Dec-15 2:32 
QuestionRe: How to communicate between two different app using SendMessage API? Pin
Richard MacCutchan30-Dec-15 2:41
mveRichard MacCutchan30-Dec-15 2:41 
AnswerRe: How to communicate between two different app using SendMessage API? Pin
Anasuya201530-Dec-15 3:06
Anasuya201530-Dec-15 3:06 
GeneralRe: How to communicate between two different app using SendMessage API? Pin
Richard MacCutchan30-Dec-15 4:29
mveRichard MacCutchan30-Dec-15 4:29 
SuggestionRe: How to communicate between two different app using SendMessage API? Pin
David Crow30-Dec-15 10:28
David Crow30-Dec-15 10:28 
AnswerRe: How to communicate between two different app using SendMessage API? Pin
Arthur V. Ratz30-Dec-15 2:42
professionalArthur V. Ratz30-Dec-15 2:42 
GeneralRe: How to communicate between two different app using SendMessage API? Pin
Anasuya201530-Dec-15 3:51
Anasuya201530-Dec-15 3:51 
GeneralRe: How to communicate between two different app using SendMessage API? Pin
Arthur V. Ratz30-Dec-15 4:27
professionalArthur V. Ratz30-Dec-15 4:27 
GeneralRe: How to communicate between two different app using SendMessage API? Pin
Arthur V. Ratz30-Dec-15 4:29
professionalArthur V. Ratz30-Dec-15 4:29 

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.