Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Functions With N arguments
#1
Hello Gintaras

Is it possible to create a function with N number of arguments? like the out statement?.

i was thinking something like:

function str'[...]

Thank you
Regards.
#2
No. Possible only with dll functions.

Workarounds:
1.Optional arguments:
function [~s1] [~s2] [~s3] [~s4] ;;max 31

2. Pass array.
function ARRAY(str)&args

3. Pass multiline string, or XML or some other string that the function would split.
function ~args
str s
foreach s args
,...

4. Pass variable of user-defined type.
function FUNC10ARGS&a
#3
Thank You Gintaras


Regards


Forum Jump:


Users browsing this thread: 1 Guest(s)