Subject: Debugging formula
Have you considered @CheckFormulaSyntax:@CheckFormulaSyntax(formulaText)
Parameters
formulaText
Text. The formula code to test for errors, commented out. Enclose the formula code in braces ({}) to comment out the code.
Return value
errorInformation
Text or textlist.
Returns “1” if the formula has no errors.
Returns the text list “errorMessage” : “errorLine” : “errorColumn” : “errorOffset” : “errorLength” : “errorText” where each list item is defined as follows:
errorMessage: Message returned by the compiler.
errorLine: Line where the error occurred, beginning with 1, not zero. New lines created by wrapped text are not counted.
errorColumn: Number of character spaces from the first character in the line where the error occurred, beginning with 1.
errorOffset: Number of character spaces from the first character in the formulaText block where the error occurred, beginning with 1.
errorLength: Length of the text making up the error.
errorText: Text or token that the compiler processes as the cause of the error.
Usage
This @function reports compile errors, not run-time errors. A run-time error is generated, for example, if a function has an insufficient number of arguments. This function is useful especially if you are using the @Eval function to execute a text expression at run-time, since you can use it to first check the syntax of any text you supply to @Eval.
Otherwise, you could use the Evaluate function in LS, and put the formula in there?