|
-
December 16th, 2003, 08:34 AM
#1
How to pass CMyDoc object or pointer to function of another class called from CMyDoc:
How to pass CMyDoc object or pointer to function of another class called from CMyDoc::Func()
Hello
I want to pass CMyDoc reference or pointer to another class function. How to do this?
Class CMydoc
{
public:
int i;
};
CMyDoc::Func()
{
}
This is class Try and is in different file - Try.cpp:
Class Try
{
FuncTry(CMydoc *pDoc);
};
Try::FuncTry(CMydoc *pDoc)
{
char cc[10];
AfxMessageBox(_itoa(cc,pDoc->i,10));
}
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|