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

C / C++ / MFC

 
AnswerRe: Serialization of enumerated types Pin
bob1697226-Sep-07 8:05
bob1697226-Sep-07 8:05 
GeneralRe: Serialization of enumerated types Pin
David Crow26-Sep-07 8:28
David Crow26-Sep-07 8:28 
GeneralRe: Serialization of enumerated types Pin
bob1697226-Sep-07 8:37
bob1697226-Sep-07 8:37 
QuestionRe: Serialization of enumerated types Pin
Nelek26-Sep-07 20:16
protectorNelek26-Sep-07 20:16 
AnswerRe: Serialization of enumerated types Pin
David Crow27-Sep-07 2:27
David Crow27-Sep-07 2:27 
GeneralRe: Serialization of enumerated types Pin
Nelek27-Sep-07 3:10
protectorNelek27-Sep-07 3:10 
QuestionLVN_ONITEMCHANGING Pin
paper6726-Sep-07 4:54
paper6726-Sep-07 4:54 
AnswerRe: LVN_ONITEMCHANGING Pin
Nelek26-Sep-07 5:37
protectorNelek26-Sep-07 5:37 
If the number of items is not very big and the time is not critical you can deal with it using a help-array.

I mean:

void CMPRSDlg::OnItemChangingMPRSLst(NMHDR *pNMHDR, LRESULT *pResult) 
{
//just at the beginning of the function
for (int i = 0; i < number_of_items; i++)
{
if (Help_array[i] == 1)
{
last_item = i;
Help_array[i] = 0;
break;           //When you find an old selected item break to have the index
}
last_item = -1;  //There was no selection before;
}
//your code to get the item that is changing

Help_array[index_of_changing_item] = 1; //Last line of your function, this will be the last selected item in the next OnChangingItem...
}


Where Help_Array has zero in ALL positions at the beggining.

Hope it helps.

Greetings.

--------
M.D.V.

If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about?

Help me to understand what I'm saying, and I'll explain it better to you

Wink | ;)

AnswerRe: LVN_ONITEMCHANGING Pin
Mark Salsbery26-Sep-07 5:46
Mark Salsbery26-Sep-07 5:46 
GeneralRe: LVN_ONITEMCHANGING Pin
paper6726-Sep-07 6:36
paper6726-Sep-07 6:36 
QuestionRe: LVN_ONITEMCHANGING Pin
Mark Salsbery26-Sep-07 7:12
Mark Salsbery26-Sep-07 7:12 
AnswerRe: LVN_ONITEMCHANGING Pin
paper6726-Sep-07 7:44
paper6726-Sep-07 7:44 
GeneralRe: LVN_ONITEMCHANGING Pin
Mark Salsbery26-Sep-07 8:05
Mark Salsbery26-Sep-07 8:05 
QuestionRe: LVN_ONITEMCHANGING Pin
Nelek26-Sep-07 20:25
protectorNelek26-Sep-07 20:25 
Questionoperator delete Pin
Waldermort26-Sep-07 4:13
Waldermort26-Sep-07 4:13 
AnswerRe: operator delete Pin
Maximilien26-Sep-07 4:25
Maximilien26-Sep-07 4:25 
AnswerRe: operator delete [modified] Pin
Randor 26-Sep-07 5:26
professional Randor 26-Sep-07 5:26 
GeneralRe: operator delete Pin
Waldermort26-Sep-07 6:23
Waldermort26-Sep-07 6:23 
Questionsyatem level Hooks related issue Pin
Sharad Goyal26-Sep-07 4:00
Sharad Goyal26-Sep-07 4:00 
AnswerRe: syatem level Hooks related issue Pin
ThatsAlok26-Sep-07 19:35
ThatsAlok26-Sep-07 19:35 
Questionthe function FILE Pin
youbo26-Sep-07 3:01
youbo26-Sep-07 3:01 
AnswerRe: the function FILE Pin
jhwurmbach26-Sep-07 3:34
jhwurmbach26-Sep-07 3:34 
AnswerRe: the function FILE Pin
toxcct26-Sep-07 3:40
toxcct26-Sep-07 3:40 
Questiongraph include? Pin
srvsah26-Sep-07 2:35
srvsah26-Sep-07 2:35 
AnswerRe: graph include? Pin
David Crow26-Sep-07 2:37
David Crow26-Sep-07 2:37 

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.