Re: Problem with IDL and fits [message #67447] |
Wed, 22 July 2009 13:20 |
pfp
Messages: 12 Registered: July 2009
|
Junior Member |
|
|
On Jul 22, 3:33 pm, David Fanning <n...@dfanning.com> wrote:
> Barbara writes:
>> I know it's in the path because I can see it in the folder that I have
>> set as my path. When i print file_which I get empty space. I can open
>> it in the editor box, but when I try to compile, it tells me it
>> doesn't exist. but obviously it does!
>
> If you don't see it with FILE_WHICH, it is *not* in
> your path. :-)
>
The reason it is not in the path could also be mismatching case in the
file name, if it is a system where case matters (such as Linux). If
the file got named "FITS_HELP.PRO", for instance, since IDL would be
looking for "fits_help.pro". If that is the case, file_which
("FITS_HELP.PRO") would find it, but just calling the procedure would
not.
The idlastro files come all in lower case in the tar file, but still
it might have been changed in a copy from a Windows filesystem, or if
the file was saved by hand (as in going to
http://idlastro.gsfc.nasa.gov/ftp/pro/fits/fits_help.pro and saving
the page contents from the browser).
|
|
|
Re: Problem with IDL and fits [message #67450 is a reply to message #67447] |
Wed, 22 July 2009 11:33  |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
Barbara writes:
> I know it's in the path because I can see it in the folder that I have
> set as my path. When i print file_which I get empty space. I can open
> it in the editor box, but when I try to compile, it tells me it
> doesn't exist. but obviously it does!
If you don't see it with FILE_WHICH, it is *not* in
your path. :-)
Download this file:
http://www.dfanning.com/misc/printpath.pro
And then run it like this:
IDL> printpath
You should see a list of the directories on your IDL
path. I'd bet some money the astronomy library isn't
there.
You could go to Window->Preferences->IDL->Paths
and add it to your IDL path, if you like.
Cheers,
David
--
David Fanning, Ph.D.
Coyote's Guide to IDL Programming (www.dfanning.com)
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
|
|
|
Re: Problem with IDL and fits [message #67451 is a reply to message #67450] |
Wed, 22 July 2009 11:25  |
Barbara
Messages: 17 Registered: July 2009
|
Junior Member |
|
|
On Jul 22, 11:21 am, David Fanning <n...@dfanning.com> wrote:
> Barbara writes:
>> I am workin on fits in IDL 7.1. I have the astro lib in my path,
>> however, IDL keeps telling me fits_help.pro doesn't exist, even though
>> I can see it and it is in the astro lib. what do I do?
>
> What makes you think it is on your path? What happens
> when you type this:
>
> IDL> Print, File_Which('fits_help.pro')
>
> How are you calling it? What happens when you call it?
> What, specifically, is the error message?
>
> Cheers,
>
> David
>
> P.S. Where is that reference to how to ask a question?
> We have needed a refresher course this week. :-(
>
> --
> David Fanning, Ph.D.
> Coyote's Guide to IDL Programming (www.dfanning.com)
> Sepore ma de ni thui. ("Perhaps thou speakest truth.")
I know it's in the path because I can see it in the folder that I have
set as my path. When i print file_which I get empty space. I can open
it in the editor box, but when I try to compile, it tells me it
doesn't exist. but obviously it does!
|
|
|
Re: Problem with IDL and fits [message #67452 is a reply to message #67451] |
Wed, 22 July 2009 11:21  |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
Barbara writes:
> I am workin on fits in IDL 7.1. I have the astro lib in my path,
> however, IDL keeps telling me fits_help.pro doesn't exist, even though
> I can see it and it is in the astro lib. what do I do?
What makes you think it is on your path? What happens
when you type this:
IDL> Print, File_Which('fits_help.pro')
How are you calling it? What happens when you call it?
What, specifically, is the error message?
Cheers,
David
P.S. Where is that reference to how to ask a question?
We have needed a refresher course this week. :-(
--
David Fanning, Ph.D.
Coyote's Guide to IDL Programming (www.dfanning.com)
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
|
|
|