Mathematica 9 is now available
Services & Resources / Wolfram Forums / MathGroup Archive
-----

MathGroup Archive 2009

[Date Index] [Thread Index] [Author Index]

Search the Archive

Problem with mathlink:PLEASE HELP ME

  • To: mathgroup at smc.vnet.net
  • Subject: [mg97623] Problem with mathlink:PLEASE HELP ME
  • From: olfa <olfa.mraihi at yahoo.fr>
  • Date: Tue, 17 Mar 2009 04:59:40 -0500 (EST)

Hi mathematica community,
Under windows xp,I have a c++ program in which I established a
comunication with mathematica via mathlink.
But when my program is executed, a "Choose a MathLink Program to
Launch" dialog box appears and ask me to choose between some
executables. This is my code and the problem should be in the path of
the connection.
In this path I have chosen to launch mathkernel.exe so why the dialog box
appears and How can I GET RID OF THIS DIALOG BOX?
Thank you, I'm very gratefull for any help.

void main(){
MLENV env;
 int error;
  MLINK ml;
   env = MLInitialize(0);

 if(env == (MLENV)0)
   { printf("unable to initialize environment"); }


   ml = MLOpenString(env,"-linkname \"C:\\Program Files\\Wolfram
Research\\Mathematica\\6.0 \\MathKernel.exe\" -mathlink",&error);


 if(ml == (MLINK)0 || error != MLEOK)
   { printf("unable to create link to the Kernel"); }


   MLActivate(ml);
   if(!MLActivate(ml))
   { printf("unable to establish communication");}
return ml;


}
}


Thank you.


  • Prev by Date: formatted table output to ascii file
  • Next by Date: Re: Two Notebooks Open at the Same Time
  • Previous by thread: Re: formatted table output to ascii file
  • Next by thread: Re: Problem with mathlink:PLEASE HELP ME