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

Home » Public Forums » archive » Function compiles (maybe) but cannot be called
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
Function compiles (maybe) but cannot be called [message #83148] Mon, 11 February 2013 10:47 Go to next message
PMan is currently offline  PMan
Messages: 61
Registered: January 2011
Member
Hello,

I have a single program that gives me a bit of a headache when I run it. It seems to compile (at least IDL says it does) but when it is called immediately afterwards, the call fails:

% Compiled module: IMGOPEN.
% Attempt to call undefined procedure/function: 'IMGOPEN'.

I have the function file name properly and it is in the path, but it appears not to actually compile. The workaround is simply to open the file and compile it manually - everything works then.

Any clues? Maybe it is a workbench setting and not really and IDL issue?

Thanks
Re: Function compiles (maybe) but cannot be called [message #83293 is a reply to message #83148] Mon, 11 February 2013 11:19 Go to previous message
PMan is currently offline  PMan
Messages: 61
Registered: January 2011
Member
On Monday, February 11, 2013 1:53:39 PM UTC-5, Mats Löfdahl wrote:
> Den måndagen den 11:e februari 2013 kl. 19:47:28 UTC+1 skrev Paul Mallas:
>
>> Hello,
>
>>
>
>>
>
>>
>
>> I have a single program that gives me a bit of a headache when I run it. It seems to compile (at least IDL says it does) but when it is called immediately afterwards, the call fails:
>
>>
>
>>
>
>>
>
>> % Compiled module: IMGOPEN.
>
>>
>
>> % Attempt to call undefined procedure/function: 'IMGOPEN'.
>
>>
>
>>
>
>>
>
>> I have the function file name properly and it is in the path, but it appears not to actually compile. The workaround is simply to open the file and compile it manually - everything works then.
>
>>
>
>>
>
>>
>
>> Any clues? Maybe it is a workbench setting and not really and IDL issue?
>
>>
>
>>
>
>>
>
>> Thanks
>
>
>
> According to http://www.astro.washington.edu/docs/idl/cgi-bin/getpro/libr ary09.html?IMGOPEN, imgopen is not a function, it is a subroutine that you are supposed to call like this:
>
>
>
> ; CALLING SEQUENCE:
>
> ; imgopen, filename, nx, ny
>
> ; INPUTS:
>
> ; filename = name of image file. in
>
> ; nx = number of pixels per image line. in
>
> ; ny = number of image lines. in

I have my own function with the same name - that is certainly my problem.

I did search my workspace (through the workbench) for that function name and nothing came up so I used that name. But a search of my workspace space through my OS, revealed that I had that library with the other imgopen on my system. I had removed it from my workbench but it was still in my path.
Re: Function compiles (maybe) but cannot be called [message #83294 is a reply to message #83148] Mon, 11 February 2013 11:02 Go to previous message
PMan is currently offline  PMan
Messages: 61
Registered: January 2011
Member
On Monday, February 11, 2013 1:53:44 PM UTC-5, Brian J. Daniel wrote:
> Is the file name all lower case? http://www.idlcoyote.com/tips/namefiles.html
>
>
>
> What version of IDL, OS?
>
>
>
> On Monday, February 11, 2013 1:47:28 PM UTC-5, Paul Mallas wrote:
>
>> Hello,
>
>>
>
>>
>
>>
>
>> I have a single program that gives me a bit of a headache when I run it. It seems to compile (at least IDL says it does) but when it is called immediately afterwards, the call fails:
>
>>
>
>>
>
>>
>
>> % Compiled module: IMGOPEN.
>
>>
>
>> % Attempt to call undefined procedure/function: 'IMGOPEN'.
>
>>
>
>>
>
>>
>
>> I have the function file name properly and it is in the path, but it appears not to actually compile. The workaround is simply to open the file and compile it manually - everything works then.
>
>>
>
>>
>
>>
>
>> Any clues? Maybe it is a workbench setting and not really and IDL issue?
>
>>
>
>>
>
>>
>
>> Thanks

Yes, it is all lower case. But Mats nailed my problem above.
Re: Function compiles (maybe) but cannot be called [message #83295 is a reply to message #83148] Mon, 11 February 2013 10:53 Go to previous message
Brian Daniel is currently offline  Brian Daniel
Messages: 80
Registered: July 2009
Member
Is the file name all lower case? http://www.idlcoyote.com/tips/namefiles.html

What version of IDL, OS?

On Monday, February 11, 2013 1:47:28 PM UTC-5, Paul Mallas wrote:
> Hello,
>
>
>
> I have a single program that gives me a bit of a headache when I run it. It seems to compile (at least IDL says it does) but when it is called immediately afterwards, the call fails:
>
>
>
> % Compiled module: IMGOPEN.
>
> % Attempt to call undefined procedure/function: 'IMGOPEN'.
>
>
>
> I have the function file name properly and it is in the path, but it appears not to actually compile. The workaround is simply to open the file and compile it manually - everything works then.
>
>
>
> Any clues? Maybe it is a workbench setting and not really and IDL issue?
>
>
>
> Thanks
Re: Function compiles (maybe) but cannot be called [message #83296 is a reply to message #83148] Mon, 11 February 2013 10:53 Go to previous message
Mats Löfdahl is currently offline  Mats Löfdahl
Messages: 263
Registered: January 2012
Senior Member
Den måndagen den 11:e februari 2013 kl. 19:47:28 UTC+1 skrev Paul Mallas:
> Hello,
>
>
>
> I have a single program that gives me a bit of a headache when I run it. It seems to compile (at least IDL says it does) but when it is called immediately afterwards, the call fails:
>
>
>
> % Compiled module: IMGOPEN.
>
> % Attempt to call undefined procedure/function: 'IMGOPEN'.
>
>
>
> I have the function file name properly and it is in the path, but it appears not to actually compile. The workaround is simply to open the file and compile it manually - everything works then.
>
>
>
> Any clues? Maybe it is a workbench setting and not really and IDL issue?
>
>
>
> Thanks

According to http://www.astro.washington.edu/docs/idl/cgi-bin/getpro/libr ary09.html?IMGOPEN, imgopen is not a function, it is a subroutine that you are supposed to call like this:

; CALLING SEQUENCE:
; imgopen, filename, nx, ny
; INPUTS:
; filename = name of image file. in
; nx = number of pixels per image line. in
; ny = number of image lines. in
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: function in form of a matrix
Next Topic: XYOUTS in 3D

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

Current Time: Wed Oct 08 15:48:35 PDT 2025

Total time taken to generate the page: 0.00630 seconds