Click here to Skip to main content
15,913,836 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
Generalauto hiding the parent Pin
Poorniselva4-Oct-04 0:11
Poorniselva4-Oct-04 0:11 
GeneralRe: auto hiding the parent Pin
Neville Franks4-Oct-04 0:14
Neville Franks4-Oct-04 0:14 
GeneralRe: auto hiding the parent Pin
Poorniselva4-Oct-04 20:42
Poorniselva4-Oct-04 20:42 
GeneralMulti-Threaded Application Pin
Sujan Christo3-Oct-04 23:51
Sujan Christo3-Oct-04 23:51 
GeneralRe: Multi-Threaded Application Pin
Neville Franks4-Oct-04 0:11
Neville Franks4-Oct-04 0:11 
GeneralRe: Multi-Threaded Application Pin
Sujan Christo4-Oct-04 0:29
Sujan Christo4-Oct-04 0:29 
GeneralRe: Multi-Threaded Application Pin
Sujan Christo4-Oct-04 1:01
Sujan Christo4-Oct-04 1:01 
GeneralRe: Multi-Threaded Application Pin
Neville Franks4-Oct-04 2:40
Neville Franks4-Oct-04 2:40 
All thread functions DataAccessThreading() are accessing the same global data and they don't know which instance of the thread they are. So the first thread to check eventShutdown[ShutThreadIndex] which see it and behave as requested.

I would wrap:

static CWinThread *multthreads[MAX_CONNECTIONS];
static CEvent m_eventShutdown[MAX_CONNECTIONS];
static HANDLE hShutDown[MAX_CONNECTIONS];
static int shutdownWait[MAX_CONNECTIONS];
static int ShutThreadIndex;


in a class and create an array of these. The pass the array instance address into the DataAccessThreading() function. Each thread knows which intance it is and only needs to check its specific eventShutdown.

Neville Franks, Author of ED for Windows www.getsoft.com and coming soon: Surfulater www.surfulater.com
GeneralThanx a lot Franks Pin
Sujan Christo4-Oct-04 18:27
Sujan Christo4-Oct-04 18:27 
GeneralRe: Multi-Threaded Application Pin
Sujan Christo5-Oct-04 0:10
Sujan Christo5-Oct-04 0:10 
GeneralRe: Multi-Threaded Application Pin
Bob Stanneveld4-Oct-04 4:25
Bob Stanneveld4-Oct-04 4:25 
GeneralRe: Multi-Threaded Application Pin
Sujan Christo4-Oct-04 21:36
Sujan Christo4-Oct-04 21:36 
GeneralRe: Multi-Threaded Application Pin
valikac4-Oct-04 6:29
valikac4-Oct-04 6:29 
GeneralChanging color of the Edit box Pin
Neelesh K J Jain3-Oct-04 23:25
Neelesh K J Jain3-Oct-04 23:25 
Generalstopwatch, timer.... Pin
marcomars3-Oct-04 23:16
marcomars3-Oct-04 23:16 
GeneralRe: stopwatch, timer.... Pin
Neville Franks4-Oct-04 0:24
Neville Franks4-Oct-04 0:24 
GeneralRe: stopwatch, timer.... Pin
David Crow4-Oct-04 4:09
David Crow4-Oct-04 4:09 
GeneralBYTE array and lists Pin
mcsherry3-Oct-04 23:01
mcsherry3-Oct-04 23:01 
GeneralRe: BYTE array and lists Pin
Antony M Kancidrowski4-Oct-04 0:37
Antony M Kancidrowski4-Oct-04 0:37 
GeneralRe: BYTE array and lists Pin
mcsherry4-Oct-04 2:32
mcsherry4-Oct-04 2:32 
GeneralRe: BYTE array and lists Pin
Antony M Kancidrowski4-Oct-04 3:52
Antony M Kancidrowski4-Oct-04 3:52 
GeneralRe: BYTE array and lists Pin
mcsherry4-Oct-04 4:30
mcsherry4-Oct-04 4:30 
GeneralRe: BYTE array and lists Pin
Robert A. T. Káldy4-Oct-04 7:11
Robert A. T. Káldy4-Oct-04 7:11 
QuestionHow can I interface PCB Borad and VC++ Program (Embedding ) Pin
Benedict Alphonse3-Oct-04 22:04
Benedict Alphonse3-Oct-04 22:04 
AnswerRe: How can I interface PCB Borad and VC++ Program (Embedding ) Pin
ThatsAlok4-Oct-04 3:52
ThatsAlok4-Oct-04 3:52 

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.