1

I'm using IDL 8.3 on Mac 10.9.3

I am running a script that calls in a procedure. The procedure I am calling in is contained in a directory that I included in IDL's path (I did this by going under IDL->preferences->IDL->paths and adding the directory). However, when I attempt to run the script, I get the error message: "% Attempt to call undefined procedure/function: 'procedure.pro'. % Execution halted at: $MAIN$". The weird thing is is that it still lists all the syntax errors in the procedure that is supposedly 'undefined'. Also, when I type the procedure.pro name into the IDL prompt, it lights up teal/blue color (meaning it recognizes the procedure).

I tried making a very simple simple.pro, put it into the same directory I mentioned before, typed it into the IDL prompt (it turned teal/blue), and it ran perfectly with no errors.

I am unsure why the procedure.pro file is 'undefined' since it is contained it its path, and I proved with simple.pro that .pro files in this path will run correctly.

DavidH
  • 415
  • 4
  • 21
deedsy
  • 57
  • 2
  • 11

2 Answers2

0

A couple of things to check:

  1. Is the routine called as a procedure and defined as a procedure (or called/defined as a function)?

  2. Does the name of the file match the name of the routine?

mgalloy
  • 2,356
  • 1
  • 12
  • 10
  • hello, yes the name of the file and procedure name are the same. It is called in as procedure, .. , .. – deedsy Jul 10 '14 at 16:13
  • The thing is is that it is still printing the syntax errors contained in the called in procedure BEFORE it says 'undefined procedure' error. So I'm wondering if I can eliminate the syntax errors if the undefined issue will then go away? – deedsy Jul 10 '14 at 16:15
0

well, the procedure I was attempting to call in contained other procedures/functions that weren't included in IDL's original library. I just had to download these separate procedures/functions, and the syntax errors went away, along with the 'unidentified procedure' error message.

deedsy
  • 57
  • 2
  • 11