Good morning,
I'm facing a pretty much doubt regarding functions in B4A.
If we want a Sub - in a module - to return 2 values in the Main, for instance, can we make the following routine:
Sub Function1 (sinput as double, sout1 as double, sout2 as double)
sout1 = 2 * sinput
sout2 = 3 * sinput
End Sub
?
It doesn't seem to work. Must we use Module1.sout1 and Module1.sout2 to retrive the values? But then, why should we pass them to the Sub?
Kind regards,
Kepler
I'm facing a pretty much doubt regarding functions in B4A.
If we want a Sub - in a module - to return 2 values in the Main, for instance, can we make the following routine:
Sub Function1 (sinput as double, sout1 as double, sout2 as double)
sout1 = 2 * sinput
sout2 = 3 * sinput
End Sub
?
It doesn't seem to work. Must we use Module1.sout1 and Module1.sout2 to retrive the values? But then, why should we pass them to the Sub?
Kind regards,
Kepler