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

Home » Public Forums » archive » (Beginner) issue setting variables using ENVI_FILE_QUERY
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: (Beginner) issue setting variables using ENVI_FILE_QUERY [message #86288 is a reply to message #86286] Wed, 23 October 2013 06:28 Go to previous messageGo to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Simon Mitchell writes:

> I am having an issue when using ENVI_FILE_QUERY to set a variable
containing the number of samples and number of lines from an opened
image. This is possibly a very simple mistake that I am making, but I
cannot see where I am going wrong (I am new to IDL, but having to update
old existing code).

> ;determine the number of samples and lines
>
> ENVI_FILE_QUERY, lun_tif, NS=ns, NL=nl
>
> The error that I am getting is:
> % PRINT: Variable is undefined: NS (PARAM).
>
> Would anyone be able to help me with this?

Instead of using ENVI_FILE_QUERY here, you want to use QUERY_TIFF:

void = Query_Tiff(ifname, fileInfo)
dims = fileInfo.dimensions
ns = dims[0]
nl = dims[1]

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
Sepore ma de ni thue. ("Perhaps thou speakest truth.")
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: xtickformat type conversion
Next Topic: Using POLYGON to plot unstructred mesh

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

Current Time: Fri Oct 10 15:23:19 PDT 2025

Total time taken to generate the page: 0.15846 seconds