I am getting the following error in report designer.
An error occurred while executing the Substring(Identifier(ARTran.TranDesc), Const(0), BinaryOp - (InStr(Identifier(ARTran.TranDesc), Const(|)), Const(1))) function. Length cannot be less than zero.
Below is the formula. It works in a GI, but not here.
=iif(InStr([ARTran.TranDesc],'|')<0,[ARTran.TranDesc],Substring([ARTran.TranDesc], 0, InStr([ARTran.TranDesc], '|') - 1))
I am trying to print all characters to the left of “|”, but this fails when there is no “|” in the string.


