Re: help with windows directory command from within idl [message #18561] |
Thu, 13 January 2000 00:00 |
Nando Iavarone
Messages: 48 Registered: December 1998
|
Member |
|
|
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
Peter Brooker wrote:
<blockquote TYPE=CITE>I am running IDL on an NT. I use the CD command to
change directories
<br>from within IDL. Staying inside IDL, I now want to list which files
are
<br>in this remote directory. The IDL command
<p>IDL> SPAWN,'DIR'
<p>Opens up a DOS window but then closes it immediatly.
<p>How can I get IDL to keep the DOS window open so I can look at the
<br>files?
<p>Is there a way other than SPAWN to list the files in the new directory?
<p>thanks-Peter Brooker</blockquote>
You can simply use the "findfile" too.
<p>fileNames = findfile()
<p>fileNames will be a string array in which each element is a file name
in your directory
<p>Bye.
<pre>--
Nando Iavarone
Advanced Computer System - SPACE DIVISION
via Lazzaro Belli, 23
00040 Frascati - RM
Tel: +39-6-944091 (switchboard)
9440968 (direct)
E-mail:
f.iavarone@acsys.it
FrdndVrn@altavista.net</pre>
</html>
|
|
|
|
Re: help with windows directory command from within idl [message #18574 is a reply to message #18561] |
Wed, 12 January 2000 00:00  |
davidf
Messages: 2866 Registered: September 1996
|
Senior Member |
|
|
Peter Brooker (ra5589@email.sps.mot.com) writes:
> I am running IDL on an NT. I use the CD command to change directories
> from within IDL. Staying inside IDL, I now want to list which files are
> in this remote directory. The IDL command
>
> IDL> SPAWN,'DIR'
>
> Opens up a DOS window but then closes it immediatly.
>
> How can I get IDL to keep the DOS window open so I can look at the
> files?
>
> Is there a way other than SPAWN to list the files in the new directory?
I use Paul Sorenson's fabulous little tool, XCD. I personally
couldn't live without it. :-)
http://www.dfanning.com/documents/programs.html
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
|
|
|