Click here to Skip to main content
12,304,884 members (70,603 online)

C / C++ / MFC

 
AnswerRe: can i use mem_fun like this? Pin
goumuli2-Dec-12 6:21
groupgoumuli2-Dec-12 6:21 
AnswerRe: can i use mem_fun like this? Pin
Stefan_Lang3-Dec-12 2:14
memberStefan_Lang3-Dec-12 2:14 
AnswerRe: can i use mem_fun like this? Pin
Stefan_Lang3-Dec-12 3:45
memberStefan_Lang3-Dec-12 3:45 
GeneralRe: can i use mem_fun like this? Pin
Falconapollo4-Dec-12 14:43
memberFalconapollo4-Dec-12 14:43 
Questionclient server for running the program Pin
danielsutopo1-Dec-12 15:09
memberdanielsutopo1-Dec-12 15:09 
AnswerRe: client server for running the program Pin
Albert Holguin1-Dec-12 17:22
memberAlbert Holguin1-Dec-12 17:22 
QuestionLimiting selected checkbox items in a CListCtrl Pin
softwaremonkey1-Dec-12 1:40
membersoftwaremonkey1-Dec-12 1:40 
SuggestionRe: Limiting selected checkbox items in a CListCtrl Pin
DavidCrow1-Dec-12 3:51
memberDavidCrow1-Dec-12 3:51 
softwaremonkey wrote:
because in changing the state of an item, it causes OnItemchangingLoadingValues() to be called again.
But the parameters (i.e., state) passed each time are different.

Rather than use a for() loop each time an item's state changes, simply check the state passed and use a counter. Then in OnItemchangingLoadingValues(), you could have something like:

void CSpecimenLoadingDialog::OnItemchangingLoadingValues(NMHDR* pNMHDR, LRESULT* pResult)
{
    if (nCheckedItems < 2)
    {
        if (pNMHDR's new state equals checked)
            nCheckedItems++;
        else
            nCheckedItems--;
    }
}

"One man's wage rise is another man's price increase." - Harold Wilson

"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons

"Show me a community that obeys the Ten Commandments and I'll show you a less crowded prison system." - Anonymous


AnswerRe: Limiting selected checkbox items in a CListCtrl Pin
Jochen Arndt1-Dec-12 23:56
memberJochen Arndt1-Dec-12 23:56 
GeneralRe: Limiting selected checkbox items in a CListCtrl Pin
softwaremonkey2-Dec-12 22:45
membersoftwaremonkey2-Dec-12 22:45 
QuestionUsing VISUAL C++ 6.0 with OLE Pin
ForNow30-Nov-12 9:06
memberForNow30-Nov-12 9:06 
AnswerRe: Using VISUAL C++ 6.0 with OLE Pin
jschell30-Nov-12 10:46
memberjschell30-Nov-12 10:46 
SuggestionRe: Using VISUAL C++ 6.0 with OLE Pin
DavidCrow30-Nov-12 14:24
memberDavidCrow30-Nov-12 14:24 
GeneralRe: Using VISUAL C++ 6.0 with OLE Pin
ForNow4-Dec-12 13:48
memberForNow4-Dec-12 13:48 
AnswerRe: Using VISUAL C++ 6.0 with OLE Pin
Stephen Hewitt2-Dec-12 4:54
memberStephen Hewitt2-Dec-12 4:54 
AnswerRe: Using VISUAL C++ 6.0 with OLE Pin
Cristian Amarie3-Dec-12 8:52
memberCristian Amarie3-Dec-12 8:52 
QuestionDll injection and hooking Pin
miniman0630-Nov-12 7:47
memberminiman0630-Nov-12 7:47 
AnswerRe: Dll injection and hooking Pin
miniman061-Dec-12 19:01
memberminiman061-Dec-12 19:01 
Questionsimple program in linux doesnt work Pin
a1_shay29-Nov-12 22:59
membera1_shay29-Nov-12 22:59 
AnswerRe: simple program in linux doesnt work Pin
Graham Breach30-Nov-12 0:24
memberGraham Breach30-Nov-12 0:24 
GeneralRe: simple program in linux doesnt work Pin
a1_shay30-Nov-12 1:43
membera1_shay30-Nov-12 1:43 
AnswerRe: simple program in linux doesnt work Pin
jschell30-Nov-12 10:49
memberjschell30-Nov-12 10:49 
QuestionRead binary File Pin
yogeshs28-Nov-12 23:05
memberyogeshs28-Nov-12 23:05 
AnswerRe: Read binary File Pin
Richard MacCutchan28-Nov-12 23:14
mvpRichard MacCutchan28-Nov-12 23:14 
AnswerRe: Read binary File Pin
Freak3028-Nov-12 23:18
memberFreak3028-Nov-12 23:18 

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.


Advertise | Privacy | Mobile
Web01 | 2.8.160530.1 | Last Updated 31 May 2016
Copyright © CodeProject, 1999-2016
All Rights Reserved. Terms of Service
Layout: fixed | fluid