Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All
MFC
TRY
Expand Minimize
Important This document may not represent best practices for current development, links to downloads and other resources may no longer be valid. Current recommended version can be found here.

AfxEndThread

Call this function to terminate the currently executing thread.

void AFXAPI AfxEndThread( 
   UINT nExitCode, 
   BOOL bDelete = TRUE  
);

nExitCode

Specifies the exit code of the thread.

bDelete

Deletes the thread object from memory.

Must be called from within the thread to be terminated.

For more information on AfxEndThread, see the article Multithreading: Terminating Threads.

Header: afxwin.h

Community Additions

ADD
Show:
© 2015 Microsoft