can you post the code that works and the code that doesnt?
NathanOliver
Posting Virtuoso
1,516 posts since Apr 2009
Reputation Points: 281
Solved Threads: 278
Skill Endorsements: 3
That error is shown when you don't create an instance of a class and right away invoke a non-static member function of it.
Are you doing that somewhere?
theguitarist
Junior Poster in Training
79 posts since May 2011
Reputation Points: 10
Solved Threads: 4
Skill Endorsements: 0
Post the block of code where the manger is used in your main function and post the code where your manger is used in another function and it doesnt work.
NathanOliver
Posting Virtuoso
1,516 posts since Apr 2009
Reputation Points: 281
Solved Threads: 278
Skill Endorsements: 3
Is mannager a member of Client or InnoVisitClient?
NathanOliver
Posting Virtuoso
1,516 posts since Apr 2009
Reputation Points: 281
Solved Threads: 278
Skill Endorsements: 3
What does the IRManager class look like? What is the code for the HangUp() function?
NathanOliver
Posting Virtuoso
1,516 posts since Apr 2009
Reputation Points: 281
Solved Threads: 278
Skill Endorsements: 3
The problem with the manager occurs in a public member function of class Client. Do I need to create an instance of the class Client inside the member function? I've never seen that.
No, no. You have IRManager* manager; in your Client class. It should be fine to invoke manager's member functions.
But, in general a static member function cannot directly call a non-static member function. Like here.
And when you say "main" function, you mean Client::_tWinMain. Right?
And the error message right at that line (manager->HangUp();) ?
theguitarist
Junior Poster in Training
79 posts since May 2011
Reputation Points: 10
Solved Threads: 4
Skill Endorsements: 0