Re: Help with writing macro

Tom Keene <[email protected]>
Newsgroups gmane.comp.openoffice.questions
Message-ID <[email protected]>
How about passing your data in an array.  Then you only need one parameter.

On Sep 21, 2011, at 12:53 PM, Grzegorz Sójka wrote:

> On 09/21/11 18:53, Johnny Rosenberg wrote:
>> I haven't done this myself, but I would try to use ”Optional” and
>> ”IsMissing”, something like this:
>> 
>> Function MyFunction(A As Double, Optional B As Double, Optional C As
>> Double) As Double
>> '	Some code
>> 	If IsMissing(B) Then
>> '		Do something
>> 	EndIf
>> 	More code
>> End Function
> This seems to be some kind of a solution. If I'm not wrong this actually implies that there is not more than 3 arguments. The problem is that there could be like 10 (or even more). Is there a way of dealing with such case without specifying 9 arguments as optional??
> -- 
> -----------------------------------------------------------------
> To unsubscribe send email to [email protected]
> For additional commands send email to [email protected]
> with Subject: help

-- 
-----------------------------------------------------------------
To unsubscribe send email to [email protected]
For additional commands send email to [email protected]
with Subject: help
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.