[scilab-Users] problem with api_list.h

ycollette.nospam at free.fr ycollette.nospam at free.fr
Thu Apr 28 11:35:28 CEST 2011


Hello,

In fact the problem was due to a lack of initialization of the mlist.
If you forget to initialize on element of the mlist, the variable is not created on the scilab stack.
You need to initialize all the elements of the mlist before the variable is created on the scilab stack.

Nest regards,

YC

----- Mail Original -----
De: "Allan CORNET" <allan.cornet at scilab.org>
À: users at lists.scilab.org
Envoyé: Jeudi 28 Avril 2011 08h04:40 GMT +01:00 Amsterdam / Berlin / Berne / Rome / Stockholm / Vienne
Objet: RE: [scilab-Users] problem with api_list.h




Hi, 



See : 



http://bugzilla.scilab.org/show_bug.cgi?id=7227 



current sendScilabJob function made to be used by a external program and not by scilab. 



Best regard 



Allan 





De : Yann Chapalain [mailto:yann.chapalain at gmail.com] 
Envoyé : mercredi 27 avril 2011 17:27 
À : users at lists.scilab.org 
Objet : [scilab-Users] problem with api_list.h 



Hello, 

I try to create a MList like this : 

SciErr _SciErr; 
int * piMList = NULL; 
_SciErr = createNamedMList(pvApiCtx, "Dakota", SCI_NUMBER_OF_FIELDS, &piMList); 
if (_SciErr.iErr) 
{ 
Cerr << "Error (Direct:Scilab): 1 "<< std::endl; 
printError(&_SciErr,0); 
} 

When I launch the code, there is no error seems to be happening. 

After, I use SendScilabJob to take control of Scilab, and to test if the MList was created ("who") : 

SendScilabJob("pause;"); 

But, I constat that the MList Dakota was not created. 

However, when I did the same manipulation with : _SciErr = createNamedMatrixOfDouble(pvApiCtx, "Dakota", 1, 1, &tmp_dbl); 
the MatrixOfDouble Dakota was created. 


anybody know s where is the problem ? 

Regards, 

Yann



More information about the users mailing list