Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Passing AfxBeginThread a Class Function

Posted on 1998-06-10
1
Medium Priority
?
1,048 Views
Last Modified: 2013-11-20
Is it possible to pass a function such as AfxBeginThread, a pointer to a Class Member Function.  So far I've only been able to create stand-alone functions (CALLBACK), and use their name to pass to functions like AfxBeginThread.

Is it possible, and can some one show me an example please?

eg
class cblah
{
  int blahfunct();
  void mainfunc();
}

class blah::mainfunc()
{
  AfxBeginThread(blahfunct, ..., ..., ..., ...);
}
This is only an example..not actual code!
0
Comment
Question by:jubjub
1 Comment
 
LVL 1

Accepted Solution

by:
Andy_Keys earned 400 total points
ID: 1317835
Only if you make the it a static member fn. eg
class cblah
{
  static int blahfunct();
  void mainfunc();
}

0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction: Load and Save to file, Document-View interaction inside the SDI. Continuing from the second article about sudoku.   Open the project in visual studio. From the class view select CSudokuDoc and double click to open the header …
If you use Adobe Reader X it is possible you can't open OLE PDF documents in the standard. The reason is the 'save box mode' in adobe reader X. Many people think the protected Mode of adobe reader x is only to stop the write access. But this fe…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Whether it be Exchange Server Crash Issues, Dirty Shutdown Errors or Failed to mount error, Stellar Phoenix Mailbox Exchange Recovery has always got your back. With the help of its easy to understand user interface and 3 simple steps recovery proced…
Suggested Courses

877 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question