comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: giving input to fortran program using spawn in IDL
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: giving input to fortran program using spawn in IDL [message #62693 is a reply to message #62692] Wed, 24 September 2008 09:17 Go to previous messageGo to previous message
Craig Markwardt is currently offline  Craig Markwardt
Messages: 1869
Registered: November 1996
Senior Member
rammaur@gmail.com writes:

> Dear all,
>
> I have some programs written in fortran-77. I want to run them
> in
> the IDL editor. I tried using spawn command. Which is good only if I
> am not worry about input to fortran from IDL itself. The result from
> spawn can be split according our fortran program.
>
> But I am creating some data from IDL, which is required for
> fortran
> as input. I search on the web and tried myself. But I could not make
> it.

If you are using Unix or Mac OS X, you can use the various redirection
capabilities of those operating systems. For example, put the inputs
in a text file, and then,
SPAWN, 'my_fortran_program < inputfile.txt', output_results

If you need dynamic control, you will want to use the UNIT keyword for
SPAWN, which provides a file unit you can write to. I.e. you would
PRINTF your inputs to that file unit. That can be very subtle
however, so it's better to use the above construction if you can.

If you have windows, I'm less well informed.

Good luck,
Craig


--
------------------------------------------------------------ --------------
Craig B. Markwardt, Ph.D. EMAIL: cbmarkwardt+usenet@gmail.com
------------------------------------------------------------ --------------
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Possible to display .h5 ad .hdf together
Next Topic: Re: Possible to display .h5 ad .hdf together

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 19:50:31 PDT 2025

Total time taken to generate the page: 1.04228 seconds