Readers

Does anyone have experience with combining REALbasic GUIs with executables made with a Fortran compiler?

What is the most elegant way to call Fortran-made executables from within REALBASIC? I have been using the mode=0 (synchronous) shell.execute command. However, I find it very limiting. I do not want the user to see any UNIX, so the idea to to hide all system and other calls behind buttons. Interactive shell mode is available only in OSX, so that rules that out...

For example, say my executable is in directory A and the input file needed by the executable in Directory B while I want the out saved to Directory B (to make it easy).

How would one implement that?

See below what I did when everything is in the same directory:

************

 Dim makegrd As Shell
 Dim errmess,workdir,executable As String
 makegrd=New Shell
 makegrd.Mode=0

 workdir="/Volumes/SRC/fortran/k_surf_new/"
 executable="/Volumes/SRC/fortran/k_surf_new/a.out"

 makegrd.Execute("cd"+""+" "+""+workdir+";"+" "+executable)
 errmess=makegrd.Result
 MsgBox errmess
 if errmess="" then
   MsgBox "No output messages"
   If makegrd.errorCode = 0 then
     MsgBox "Grid has been created"
   end if
 else
   MsgBox errmess
 end if

***********

I am happy with this result so far, but how does one call a series of system commands, such as

rlogin node1
cd dir/a
nohup ./runit &
exit

without hardcoding it into a shell script and calling the script?


Dr. Johannes N. Theron


_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Reply via email to