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

Home » Public Forums » archive » Re: open files in some directory
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: open files in some directory [message #32950] Mon, 18 November 2002 22:32 Go to previous message
tom is currently offline  tom
Messages: 28
Registered: April 1995
Junior Member
Thanks David very much.

"David Fanning" <david@dfanning.com> д����Ϣ����
:MPG.184360d7231da617989a2f@news.frii.com...
> tom (tom2959@21cn.com) writes:
>
>> Hi, I'd like to open one file in a directory. For example,
>> openr,1,'d:\data\1.txt'
>> but next time maybe open 2.txt in that directory. I donot want to change
the
>> code every time. Are there any method when the program excute at openr,
a
>> window containing the files can jump out and then I can chose files in
the
>> directory to be opened? Somebody told me Matlab code:
>> [fname,fpath]=uigetfile('*.*','Data'), but I donot use Matlab.
>
> How about something like this:
>
> filename = Dialog_Pickfile(Filter='*.txt', Path='D:\Data\')
> IF filename EQ "" THEN RETURN
> OpenR, lun, filename, /Get_Lun
>
> You shouldn't have to learn MatLab just to read the
> name of your data file into your program. :-)
>
> Cheers,
>
> David
>
> --
> David W. Fanning, Ph.D.
> Fanning Software Consulting, Inc.
> Phone: 970-221-0438, E-mail: david@dfanning.com
> Coyote's Guide to IDL Programming: http://www.dfanning.com/
> Toll-Free IDL Book Orders: 1-888-461-0155
[Message index]
 
Read Message
Read Message
Previous Topic: Re: CAT, DOG, 1.7 AND FISH IN IDL
Next Topic: FONT setting

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

Current Time: Fri Oct 10 06:35:26 PDT 2025

Total time taken to generate the page: 1.20089 seconds