Click here to Skip to main content
15,903,362 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Disconnection of LAN cable abruptly Pin
Moak14-Oct-09 9:56
Moak14-Oct-09 9:56 
QuestionChanging Default Icon in MFC Pin
Hari_1614-Oct-09 1:31
Hari_1614-Oct-09 1:31 
AnswerRe: Changing Default Icon in MFC Pin
Game-point14-Oct-09 1:41
Game-point14-Oct-09 1:41 
GeneralRe: Changing Default Icon in MFC Pin
Hari_1614-Oct-09 1:54
Hari_1614-Oct-09 1:54 
AnswerRe: Changing Default Icon in MFC Pin
CPallini14-Oct-09 1:54
mveCPallini14-Oct-09 1:54 
GeneralRe: Changing Default Icon in MFC Pin
Hari_1614-Oct-09 1:59
Hari_1614-Oct-09 1:59 
GeneralRe: Changing Default Icon in MFC Pin
CPallini14-Oct-09 2:12
mveCPallini14-Oct-09 2:12 
GeneralRe: Changing Default Icon in MFC Pin
Hari_1614-Oct-09 2:08
Hari_1614-Oct-09 2:08 
QuestionNetServerDiskEnum Example Pin
Abinash Mohanty14-Oct-09 1:29
Abinash Mohanty14-Oct-09 1:29 
AnswerRe: NetServerDiskEnum Example Pin
Richard MacCutchan14-Oct-09 2:08
mveRichard MacCutchan14-Oct-09 2:08 
GeneralRe: NetServerDiskEnum Example Pin
Abinash Mohanty14-Oct-09 18:07
Abinash Mohanty14-Oct-09 18:07 
GeneralRe: NetServerDiskEnum Example Pin
Richard MacCutchan14-Oct-09 21:59
mveRichard MacCutchan14-Oct-09 21:59 
GeneralRe: NetServerDiskEnum Example Pin
Abinash Mohanty14-Oct-09 23:09
Abinash Mohanty14-Oct-09 23:09 
QuestionMultithreaded App Pin
Manmohan2913-Oct-09 23:27
Manmohan2913-Oct-09 23:27 
AnswerRe: Multithreaded App Pin
CPallini13-Oct-09 23:45
mveCPallini13-Oct-09 23:45 
AnswerRe: Multithreaded App Pin
Game-point14-Oct-09 1:16
Game-point14-Oct-09 1:16 
AnswerRe: Multithreaded App Pin
Rajesh R Subramanian14-Oct-09 2:05
professionalRajesh R Subramanian14-Oct-09 2:05 
GeneralRe: Multithreaded App Pin
Manmohan2914-Oct-09 4:14
Manmohan2914-Oct-09 4:14 
AnswerRe: Multithreaded App Pin
Rajesh R Subramanian14-Oct-09 4:16
professionalRajesh R Subramanian14-Oct-09 4:16 
Manmohan29 wrote:
UINT CThreadDlg::ThreadFunc(LPVOID pParam) //---> Here is the problem!
{
return 0;
}

void CThreadDlg::OnBnClickedBthread()
{
// TODO: Add your control notification handler code here
AfxBeginThread(ThreadFunc, this);
}


The thread function should be a global function (not a member function of any class), or it must be a static member function of any class. Try this instead:

in your header file:
static UINT CThreadDlg::ThreadFunc(LPVOID pParam);

in the source file:
/*static*/ UINT CThreadDlg::ThreadFunc(LPVOID pParam){
OutputDebugString(_T("*********** Entered thread function ***********\n"));
return false;
}


Watch the output window of your debugger to see the text printed from your thread.


“Follow your bliss.” – Joseph Campbell

GeneralRe: Multithreaded App Pin
Roger Stoltz14-Oct-09 4:27
Roger Stoltz14-Oct-09 4:27 
GeneralRe: Multithreaded App Pin
Rajesh R Subramanian14-Oct-09 4:30
professionalRajesh R Subramanian14-Oct-09 4:30 
GeneralRe: Multithreaded App Pin
Manmohan2914-Oct-09 5:55
Manmohan2914-Oct-09 5:55 
Questionresolving link error LNK1241 Pin
KASR113-Oct-09 19:40
KASR113-Oct-09 19:40 
AnswerRe: resolving link error LNK1241 Pin
David Crow14-Oct-09 2:40
David Crow14-Oct-09 2:40 
QuestionCursor in edit box Pin
sonualex13-Oct-09 18:53
sonualex13-Oct-09 18:53 

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.