Hi,
I have to get last 2 characters of a string using X++ code.
Eg: If my inputStr = 'QWERTY'
then i should get my outputStr = TY
I tried the below code but it doesn't seem to work, can someone help me
str InputString = 'QWERTY';
str OutputString = subStr(warehouseString, (StrLen(InputString)-2), -2);
str OutputString = subStr(warehouseString, (StrLen(InputString)-2), -2);
If my input string changes to POWER004 then my output string should be 04, can someone help me with the correct code.
Categories:
