Error with mex function
Mostra commenti meno recenti
Hello,
I keep receiving the following error and I want to see if anyone can tell me whats wrong. I'm sure its an easy fix I just can't find it. The error I receive from my own code as follows "Error getting T/F from input #2."
The following is part of code concerning this error
SumFile_pr = mxGetField(prhs(ArgNum),1,'WrSumFile')
ErrStat = mxGetString(SumFile_pr, ADOptions%WrSumFile, M*N)
IF (ErrStat /= 0) CALL ProgAbort('Error getting T/F from input #2.')
I use the following as my matlab struct.
ADOptions.WrSumFile = '.False.'
Then using results = mymexfunction(ADOptions, othervariables) in matlab. Any advice is appreciated.
2 Commenti
Kaustubha Govind
il 8 Ago 2012
What is ADOptions%WrSumFile supposed to represent? The second argument to mxGetString needs to be a pre-allocated character buffer. See the bottom of the mxGetString help page for examples of usage.
Chris
il 8 Ago 2012
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Fortran with MATLAB in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!