Re: Input parameters in a DOS menu driven routine. [message #34329 is a reply to message #34319] |
Wed, 05 March 2003 22:45  |
Rick Towler
Messages: 821 Registered: August 1998
|
Senior Member |
|
|
"Luciano" wrote
> I have a fortran exe file which I run, then I have to input some
> parameters and finally I obtain a result (this all happens of course
> in a DOS window).
> Now, how can I do this from IDL? I can call the file with Spawn but
> then how do I input the parameters? I was trying to Spawn a batch file
> wich runs some programs I found on the web which simulate pre-defined
> keystrokes, but all of them have the problem that no more than 15
> keystrokes could be passed (I need more than 15)...
Do you have access to the source? I think it will be easiest to modify the
source to either accept command line parameters or read the params from a
file. My guess is that if you have gone this far you don't but I had to
ask.
If you don't... Hope that you can find one of these programs that allows
more than 15 keystrokes. I am pretty sur this is your only option.
> Of course there is also the question on how do I take the final result
> of the fortran routine back to IDL...
If you can use spawn, spawn can return the result:
IDL> spawn, 'echo hello there', out
IDL> print,out
hello there
-Rick
|
|
|