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

Home » Public Forums » archive » passing parameters on to other functions
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
passing parameters on to other functions [message #8772] Tue, 22 April 1997 00:00 Go to next message
bandari is currently offline  bandari
Messages: 2
Registered: September 1996
Junior Member
Hi:
I want to pass the parameters that have been sent to
a function directly to another function or procedure. The difficulty
is that there may be optional keywords and optional functions that are
also needed to be passed on.

One obvious option would be to use a series of nested ifs, but
this can get messy as the number of optional parameters increase. I
have also resorted to using the 'execute command', but there just must
be a cleaner way of handling this issue. Any ideas anyone?

I was thinking, for instance, that if there was a way of setting
undefined keywords/parameters to something that is still undefined,
without idl complainning, then all one has to do is pass ll the parameters
to the next function (undefined parameters will still remain undefined and
everybody will be happy. Thanks in advance for all the help.


--- Esfandiar


--
Esfandiar B. Bandari, Ph.D. email: bandari@mda.ca
MacDonald Dettwiler and Assoc. tele: o. (604) 231-2374
13800 Commerce Parkway h. (604) 926-4839
Richmond, B.C. V6V 2J3 fax: (604) 278-2117
Re: passing parameters on to other functions [message #8878 is a reply to message #8772] Thu, 01 May 1997 00:00 Go to previous message
Robert Moss is currently offline  Robert Moss
Messages: 74
Registered: February 1996
Member
Esfandiar Bandari wrote:
>
> Hi:
> I want to pass the parameters that have been sent to
> a function directly to another function or procedure. The difficulty
> is that there may be optional keywords and optional functions that are
> also needed to be passed on.
>
> One obvious option would be to use a series of nested ifs, but
> this can get messy as the number of optional parameters increase. I
> have also resorted to using the 'execute command', but there just must
> be a cleaner way of handling this issue. Any ideas anyone?
>
> I was thinking, for instance, that if there was a way of setting
> undefined keywords/parameters to something that is still undefined,
> without idl complainning, then all one has to do is pass ll the parameters
> to the next function (undefined parameters will still remain undefined and
> everybody will be happy. Thanks in advance for all the help.
>
> --- Esfandiar
>
>
> --
> Esfandiar B. Bandari, Ph.D. email: bandari@mda.ca
> MacDonald Dettwiler and Assoc. tele: o. (604) 231-2374
> 13800 Commerce Parkway h. (604) 926-4839
> Richmond, B.C. V6V 2J3 fax: (604) 278-2117


There is already a builtin mechanism to handle this called keyword
inheritance. Look up the EXTRA keyword in your online help for more
details. It's custom made for just your problem.

--
Robert M. Moss, Ph.D. - mossrm@texaco.com - FAX (713)954-6911
------------------------------------------------------------ -----
This does not necessarily reflect the opinions of Texaco Inc.
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: STATIC VARIABLES
Next Topic: IDL, Mathematica, Matlab

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

Current Time: Wed Oct 08 13:48:51 PDT 2025

Total time taken to generate the page: 0.00465 seconds