Re: problem on C++ Shared Library
- From: Jeffrey <sunshinejeffrey@xxxxxxxxxxx>
- Date: Tue, 10 Apr 2007 14:25:43 -0400
Thank you very much, John. I didn't know I was so careless :-)
But I still have a problem, for example:
After I call libFuncOneTerminate, I cannot call
libFuncTwoInitialize(), becasue there's an error message says:
"Unhandled exception at 0x006ea8c1 (mfc80ud.dll) in RecdEnvrnmt.exe:
0xC0000005: Access violation reading location 0xf78e2430."
void CDlg::OnBnClicked()
{
mclInitializeApplication(NULL,0);
libFuncOneInitialize()); //FuncOne
mlfFuncOne();
libFuncOneTerminate();
libFuncTwoInitialize(); //FuncTwo
mlfFuncTwo();
libFuncTwoTerminate();
mclTerminateApplication();
}
I wonder if someone has met this problem. I appreciate the help very
much!
John Reilly wrote:
a
Hi Jeff,
The documentation clearly says:
After you call mclTerminateApplication, you may not call
mclInitializeApplication again. No MathWorks functions may be
called
after mclTerminateApplication.
The page is in the MATLAB Compiler documentation, and is entitled
"Calling a Shared Library"
john.
Jeffrey wrote:
Hello,
I created a MFC program which invokes a function generated from
executed,.mwell.
file by matlab.
The problem is: the first time I call this function, it works
But after
mclTerminateApplication();
when I want to call the function for a second time, there is a
problem with mclInitializeApplication();
That means, once the mclTerminateApplication() has been
.mclInitializeApplication() fails to be executed again.
Does anyone meet this problem? Thank you very much!
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
My problem: The second time I click the button,
mclInitializeApplication fails to start.
void CDlg::OnBnClicked()
{
mclInitializeApplication(NULL,0);
libTESTInitialize());
mlfTEST();
libTESTTerminate();
mclTerminateApplication();
}
- References:
- problem on C++ Shared Library
- From: Jeffrey
- Re: problem on C++ Shared Library
- From: John Reilly
- problem on C++ Shared Library
- Prev by Date: Re: for loop to sum matrix
- Next by Date: Re: Iterative solution using Solve (problems with symbolic input)
- Previous by thread: Re: problem on C++ Shared Library
- Next by thread: what relationship between matlab and simulink?
- Index(es):
Loading