Click here to Skip to main content
15,894,180 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Change Application Icon Pin
toxcct15-Feb-06 3:32
toxcct15-Feb-06 3:32 
GeneralRe: Change Application Icon Pin
sunit515-Feb-06 3:39
sunit515-Feb-06 3:39 
AnswerRe: Change Application Icon Pin
Wim Engberts15-Feb-06 4:12
Wim Engberts15-Feb-06 4:12 
GeneralRe: Change Application Icon Pin
ThatsAlok16-Feb-06 2:44
ThatsAlok16-Feb-06 2:44 
GeneralRe: Change Application Icon Pin
Wim Engberts16-Feb-06 5:21
Wim Engberts16-Feb-06 5:21 
GeneralRe: Change Application Icon Pin
ThatsAlok16-Feb-06 17:18
ThatsAlok16-Feb-06 17:18 
QuestionSir,I want 2 know that weather we can call SAME function in Multiple Threads? Pin
CodeVarma15-Feb-06 3:18
CodeVarma15-Feb-06 3:18 
AnswerRe: Sir,I want 2 know that weather we can call SAME function in Multiple Threads? Pin
Tim Smith15-Feb-06 3:35
Tim Smith15-Feb-06 3:35 
In C/C++, local variables are stack based so any variables declared inside of the routine are ok unless they are static.

The problem boils down to the routine trying to access the same piece of data in two threads. If this is what is happening, then you will have problems unless the data is read only and will never be written to.

For example:

int Sum (int a, int b)
{
int c = a + b;
return c;
}

This routine can be called from many threads at the same time.

For example:

int value = 0;

void ChangeValue (int a)
{
value += a;
}

This routine will not work well unless only one thread calls the routine at a time.

Tim Smith

I'm going to patent thought. I have yet to see any prior art.
GeneralRe: Sir,I want 2 know that weather we can call SAME function in Multiple Threads? Pin
ThatsAlok16-Feb-06 2:43
ThatsAlok16-Feb-06 2:43 
GeneralRe: Sir,I want 2 know that weather we can call SAME function in Multiple Threads? Pin
Tim Smith16-Feb-06 3:40
Tim Smith16-Feb-06 3:40 
GeneralRe: Sir,I want 2 know that weather we can call SAME function in Multiple Threads? Pin
ThatsAlok16-Feb-06 17:24
ThatsAlok16-Feb-06 17:24 
AnswerRe: Sir,I want 2 know that weather we can call SAME function in Multiple Threads? Pin
BadKarma15-Feb-06 3:54
BadKarma15-Feb-06 3:54 
AnswerRe: Sir,I want 2 know that weather we can call SAME function in Multiple Threads? Pin
Stephen Hewitt15-Feb-06 16:59
Stephen Hewitt15-Feb-06 16:59 
AnswerRe: Sir,I want 2 know that weather we can call SAME function in Multiple Threads? Pin
ThatsAlok16-Feb-06 2:41
ThatsAlok16-Feb-06 2:41 
Questionmodeless dialog WM_CLOSE - opinion Pin
23_44415-Feb-06 3:14
23_44415-Feb-06 3:14 
AnswerRe: modeless dialog WM_CLOSE - opinion Pin
Shog915-Feb-06 3:46
sitebuilderShog915-Feb-06 3:46 
AnswerRe: modeless dialog WM_CLOSE - opinion Pin
Rage15-Feb-06 3:59
professionalRage15-Feb-06 3:59 
GeneralRe: modeless dialog WM_CLOSE - opinion Pin
23_44415-Feb-06 4:43
23_44415-Feb-06 4:43 
GeneralRe: modeless dialog WM_CLOSE - opinion Pin
23_44415-Feb-06 4:58
23_44415-Feb-06 4:58 
GeneralRe: modeless dialog WM_CLOSE - opinion Pin
Shog915-Feb-06 7:53
sitebuilderShog915-Feb-06 7:53 
GeneralRe: modeless dialog WM_CLOSE - opinion Pin
23_44415-Feb-06 8:00
23_44415-Feb-06 8:00 
AnswerRe: modeless dialog WM_CLOSE - opinion Pin
23_44416-Feb-06 5:17
23_44416-Feb-06 5:17 
GeneralRe: modeless dialog WM_CLOSE - opinion Pin
Shog916-Feb-06 10:32
sitebuilderShog916-Feb-06 10:32 
GeneralRe: modeless dialog WM_CLOSE - opinion Pin
23_44416-Feb-06 10:39
23_44416-Feb-06 10:39 
GeneralRe: modeless dialog WM_CLOSE - opinion Pin
Shog916-Feb-06 10:45
sitebuilderShog916-Feb-06 10:45 

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.