D
Dragon
Hi,
Is there a way to set defaults values for args of a function/sub?
For example:
Function:
public function testFunc (name as string, age as integer = 30, phone as
string)
Calling the Function:
testFunc("John", 25, "555-1212")
testFunc("John", , "555-1212") ' Age will be set to default of 30
This way one or more of arg can be left out and still have a working
function/sub.
Thank you.
Is there a way to set defaults values for args of a function/sub?
For example:
Function:
public function testFunc (name as string, age as integer = 30, phone as
string)
Calling the Function:
testFunc("John", 25, "555-1212")
testFunc("John", , "555-1212") ' Age will be set to default of 30
This way one or more of arg can be left out and still have a working
function/sub.
Thank you.