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

Home » Public Forums » archive » Bug in N_PARAMS?
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Bug in N_PARAMS? [message #64141 is a reply to message #64011] Wed, 03 December 2008 09:59 Go to previous message
R.Bauer is currently offline  R.Bauer
Messages: 1424
Registered: November 1998
Senior Member
David Fanning schrieb:
> David Fanning writes:
>
>> Carsten Lechte writes:
>>
>>> Kenneth P. Bowman wrote:
>>>> to provide default values for optional parameters.
>>> I wrote this little procedure for setting default values
>>> that I use a zillion times a day:
>>>
>>>
>>> PRO defaultarg, arg, defval, VALUEGIVEN=valuegiven
>>>
>>> IF N_ELEMENTS( arg) EQ 0 THEN BEGIN
>>> arg = defval
>>> valuegiven = 0
>>> ENDIF ELSE valuegiven = 1
>>>
>>> END
>> This is a pretty good idea. I can see how it would
>> save some typing! :-)
>>
>> Here is a slightly modified version. I'll add this,
>> with documentation, to the Coyote Library later today.
>
> I have a doppelganger at work who takes all my good ideas

hehe

you need a german keyboard or is this also an english word
"doppelganger" <-> doppelg�nger?

cheers
Reimar


> as soon as I publish them and points out all their deficiencies
> and the obvious ways in which I could have made them better. :-(
>
> To that end, I've updated the SetDefaultValue program I published
> earlier to something a good deal simpler that also works in a more
> intuitive way. You can find the update, if you are interested in
> this sort of thing, here:
>
> http://www.dfanning.com/programs/setdefaultvalue.pro
>
> Cheers,
>
> David
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: Bug in N_PARAMS?
Next Topic: Re: streamlines over contour without iVector

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

Current Time: Sun Oct 12 13:30:18 PDT 2025

Total time taken to generate the page: 1.60057 seconds