Re: call_procedure with a dynamically created arguments list? [message #50614 is a reply to message #50613] |
Fri, 06 October 2006 14:11  |
Jean H.
Messages: 472 Registered: July 2006
|
Senior Member |
|
|
in "some_proc", if you receive args[] with only 1 element in it. How
would you know if it is the value of foo or of bla?
Jean
Dometz wrote:
> I have already discussed this with a few of you but wanted to see if
> anyone else might know a way of doing the following:
>
> Is it possible to do something like:
>
> foo = "bar"
> bla = 'blu"
> args=[]
> if (N_ELEMENTS(foo) ne 0) then
> args=[args, foo]
> if (N_ELEMENTS(bla) ne 0) then
> args=[args, bla]
>
> CALL_PROCEDURE('some_proc', args)
>
> So, the goal is to build dynamically an arguments list that will be
> passed in to CALL_PROCEDURE, CALL_FUNCTION or CALL_METHOD. (I want to
> avoid EXECUTE)
>
> thanks,
>
> dometz
>
> PS: My goal is to write a transparent wrapper for IDL functions. So, I
> would like that when using the wrapper or not, "everything" (including
> error message) stays the same.
>
> PS2: David: Yeah, I still havent given up on this. ;-)
>
|
|
|