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

Home » Public Forums » archive » Re: Return the name of the last (newest) file ?
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: Return the name of the last (newest) file ? [message #31671 is a reply to message #31670] Tue, 13 August 2002 11:47 Go to previous messageGo to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Kolbjorn Bekkelund (kobe@rocketrange.no) writes:

> Thanks for the tip.
> I tried it and the print command shows the correct file, but:
> When I try to use the contents of lastfile as an input like
>
> data=read_ascii(lastfile,data_start=1)
>
> I get:
>
> MESSAGE: Expression must be a scalar in this context: <STRING
> Array[1]>
>
> I got the same earlier today when I tried to use the spawn, 'date',
> mydate. I solved that one by using systime() though. What is it telling
> me ?

It's telling you the variable is an array, and it should
be a scalar. It happens to be an array with only one element
in it, however, so use it like this:

data=read_ascii(lastfile[0],data_start=1)

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
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: Scrolling in draw widgets - newbie's question
Next Topic: Return the name of the last (newest) file ?

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

Current Time: Thu Oct 09 20:00:04 PDT 2025

Total time taken to generate the page: 1.20416 seconds