Small bug in doc (function return)
Posted: 16 Apr 2014 11:53
For ScriptUtils.RegExPos (and for other similar functions) the doc states:
(I tested with ScriptUtils.RegExPos only, though.)
In fact it is -1, not 0, as I just learnt:If nothing is found, the function returns 0 (zero).
Code: Select all
for (var i = 0; i < Document.LineCount; i++) {
x = ScriptUtils.RegExPos("^\\s+", Document.Lines[i], exp);
ShowMessage(x);
}