+ 1
Is it possible to to declare a function which returns two parameters using out and also has a third parameter which is recieved?
I was wondering if I have to take a parameter to use in a function but also return two as answers using out.
2 Réponses
+ 1
The functions in C# can receive any number of parameters and out any number of parameters so it's possible just like this :
public bool MyFunction(string receivedPar1,string receivedPar2, out string outPar1, out string outPar2)
but you have to assign values for all out parameters before return from the function.
+ 1
thanks