Re: Finding the path of the IDL executable [message #45583] |
Tue, 20 September 2005 09:23 |
Rick Towler
Messages: 821 Registered: August 1998
|
Senior Member |
|
|
Ricardo Bugalho wrote:
> Anyone knows of a way to find out the path of the executable of the
> current IDL session?
> I have an IDL program that launches other IDL sessions and I need to know
> the path to the "idl" executable.
You could take Antionio's !DIR suggestion, add a bit of PATH_SEP()+'bin'
and flavor with the recursive file_search() function and parse that. I
would think this would be the most robust solution.
-Rick
|
|
|
Re: Finding the path of the IDL executable [message #45593 is a reply to message #45583] |
Tue, 20 September 2005 02:40  |
Ricardo Bugalho
Messages: 22 Registered: March 2005
|
Junior Member |
|
|
On Mon, 19 Sep 2005 11:06:23 -0500, Michael Wallace wrote:
> If on *nix, you can spawn a call to the system's which command ("which
> idl") and it will tell you the path of the IDL executable. You might need
> to play with this command a little if the path is an alias.
Oh, I'm trying to make this portable between Unix and Windows! You may
call me insane now. :)
I'm going by Andrew's suggestions and parse the contents of !DLM_PATH.
|
|
|
Re: Finding the path of the IDL executable [message #45597 is a reply to message #45593] |
Mon, 19 September 2005 22:52  |
Antonio Santiago
Messages: 201 Registered: February 2004
|
Senior Member |
|
|
Ricardo Bugalho wrote:
> Hello group!
> Anyone knows of a way to find out the path of the executable of the
> current IDL session?
> I have an IDL program that launches other IDL sessions and I need to know
> the path to the "idl" executable.
>
> Thanks
What about !DIR (or IDL_PATH evnironment variable) ??
--
-----------------------------------------------------
Antonio Santiago P�rez
( email: santiago<<at>>grahi.upc.edu )
( www: http://www.grahi.upc.edu/santiago )
( www: http://asantiago.blogsite.org )
-----------------------------------------------------
GRAHI - Grup de Recerca Aplicada en Hidrometeorologia
Universitat Polit�cnica de Catalunya
-----------------------------------------------------
|
|
|
|
Re: Finding the path of the IDL executable [message #45610 is a reply to message #45607] |
Mon, 19 September 2005 09:06  |
Michael Wallace
Messages: 409 Registered: December 2003
|
Senior Member |
|
|
Ricardo Bugalho wrote:
> Hello group!
> Anyone knows of a way to find out the path of the executable of the
> current IDL session?
> I have an IDL program that launches other IDL sessions and I need to know
> the path to the "idl" executable.
If on *nix, you can spawn a call to the system's which command ("which
idl") and it will tell you the path of the IDL executable. You might
need to play with this command a little if the path is an alias.
-Mike
|
|
|