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

Home » Public Forums » archive » Syntax error while compiling IDL code
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Syntax error while compiling IDL code [message #38877] Wed, 07 April 2004 12:20
guptaparesh7 is currently offline  guptaparesh7
Messages: 3
Registered: April 2004
Junior Member
Hello Everyone,
When I try to compile the following .pro file using IDL 6.0, I get
a syntax error message given below.


------------------------------------------------------------ --------------
IDL> .compile approach

dmazid=map_2points(elk(k),nlk(k),elz(j),nlz(j),/METERS)
^
% Syntax error.
At: /disk/151/oracle/j2ee/home/default-web-app/WEB-INF/classes/F DOIclasses/IDLCode/windmodel/GEMPLEX_04_01_04/MODULES_VM/app roach.pro,
Line 17
% 1 Compilation error(s) in module APPROACH.
IDL>
------------------------------------------------------------ ---------------

---------------------------------------------------------
PRO APPROACH,k,elk,nlk,elz,nlz,range,zpstc
compile_opt hidden
on_error,1

;...preamble
if n_params() eq 0 then begin
print,'APPROACHX,k,elk,nlk,elz,nlz,range,zpstc'
return&endif

;...collect zipcodes which are within range of current center
kinc=1 & k=-kinc & nzip=n_elements(elz)
labela: k=k+kinc & dc2zip=1000.
if k+1 gt n_elements(elk) then return

;...build table of distances of all zipcodes from current center
for j=0,nzip-1 do begin

;*********************************************************
; this is where I am getting the error message...
dmazid=map_2points(elk(k),nlk(k),elz(j),nlz(j),/METERS)
;*********************************************************

dc2zip=[dc2zip,1e-3*dmazid(0)] &endfor & dc2zip=dc2zip(1:*)

;...select only those zipcodes within range of the storm center
izip=where(dc2zip le range,ict) & if ict eq 0 then goto,labela

;...for each center fix collect effected zipcodes in structure
zpstc={index:k,jndice:izip,elz:elz(izip),nlz:nlz(izip)}
END ;APPROACH.PRO

---------------------------------------------------------

Any kind of help would be appreciated.
I am a complete novice to IDL.

Thanks!
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: IDL crashes/hangs while reading images
Next Topic: Re: /BLOCK vs. /NO_BLOCK in .sav-files

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

Current Time: Sat Oct 11 00:18:18 PDT 2025

Total time taken to generate the page: 0.84760 seconds