Epicor function non mandatory parameter


I would like to know if it’s possible to have a non mandatory parameter in an Epicor Function???

ie: funcA(string pParam1 = “”);


Epicor Help says that Function Parameter is Optional:


In the function signature you can select one of the data types with the “?” to use the Nullable type

Technically you could create two different functions with different parameter lists. Then the first function can call the second function with the default parameter (so you don’t have to duplicate the full function). You will just have to have different names on the two functions.

It would probably be easier to use @mikelyndersOKCC’s suggestion and use the nullable type and test in your function for that case.

It is possible only if functions have different names.

1 Like

That’s what I meant, although that’s not what I said :grin:

I’ve pointer that just because it is not normal for C#/C++ developers :wink:
It is implemented this way to be more HTTP compatible