Hi experts,
I need to convert a string to a enum value.
The scenerio is, the string value is Open Order and it has to be converted to the enum value of salesstatus baseenum.
I have tried the below code.
assume “orderStatus” string variable contain “OpenOrder”
Salesstatus _salesStatus;
;
_salesStatus = str2enum(_salesStatus, orderStatus);
It is not working and _salesStatus is getting backOrder values in the enum irrespective of the string in the “orderStatus”.