warning T0020:In the function '%s', the mandatory parameter %s is specified after optional parameter.

Cause

This warning appears when a mandatory parameter is mentioned in a function definition after an optional parameter.

Solution

Make sure optional parameter is always mentioned at the end of the parameter list.

Example

[#Menu: Gateway Of Tally]

Add: Item: "MyFunc": Call: MyFunc

[Function: MyFunc]

000: Call: MyFunc2

[Function: MyFunc2]

Parameter: pVar1: String: "Var1"

Parameter: pVar2: String

In the example, the parameter pVar2 is a mandatory parameter which is mentioned after an optional parameter pVar1. Hence the message warning T0020: In the function 'MyFunc2', the mandatory parameter 'pVar1' is specified after optional parameter appears.

The code is corrected by adding the optional parameter at the end.

[#Menu: Gateway Of Tally]

Add: Item: "MyFunc": Call: MyFunc

[Function: MyFunc]

000: Call: MyFunc2: "Var2"

[Function: MyFunc2]

Parameter: pVar2: String

Parameter: pVar1: String: "Var1"