I found the answer to my question.
I want to thank me warmly (and Lexicos !!!).
At first, without initialising it (by giving values to the keys), I declare the associative array with a "Global" instruction outside the function to make it available everywhere, as it is now a Super Global variable (thanks Lexicos). If I would not made that, the array named "TheFunc_Params"
would be only available inside the function. Once we go back to the caller, the array would no longer exists, as it would be local to the function, so we can't get back any value.
The array is declared Super Global but the values are affected to the keys inside the function, and I can have as many keys that I want to return the appropriate number of values to the caller. That's what I wanted...
The second modification I made is to use multi-dimensionnal associative array, with the correct syntax (see Param2 and Param4)...
So now, I can return as many values that I want in an associative array that is associated with one of the keys of the associative array used as the argument of the function !!!
May be it sounds complicated,
but it is a very flexible solution. You can use an associative array as the sole argument of a function, which can pass as many parameters as you want to the function, and the same for the return values. And you can even return an array of parameters associated with one of the keys of the associative array of parameters used as the argument of the function, when your function, depending of some circumstances, may return a variable number of results to the caller.
Here is the code :
Code:
Lib_Func_Params := {ParamOne: 0, ParamTwo: "Value B", ParamThree: 24, ParamFor: "", ParamFive: "goubiboulga"}
Global TheFunc_Params
x := TheFunc(Lib_Func_Params, VariaParam*)
Param3 := Lib_Func_Params["ParamThree"]
Param2 := Lib_Func_Params["ParamFor","Par2"]
Param4 := Lib_Func_Params["ParamFor"]["Par5"]
msgbox Param Three "%Param3%"
msgbox Param Four "%Param4%"
msgbox Param Two "%Param2%"
TheFunc(ByRef ParamArray, variaParam*)
{
ParamArray["ParamThree"] := 25
TheFunc_Params := {Par1: 0, Par2: "Value C", Par3: 24, Par4: "", Par5: "coucoulina"}
ParamArray["ParamFor"] := TheFunc_Params
}