Re: Semicolon in regex causes error in SetListDelimiter statement
- --- In firstname.lastname@example.org, "Sheri" <silvermoonwoman@...> wrote:
>Thank you, Sheri, for the quick reply with the quote suggestion and for the reason for my problem. I'd not have figured that one out.
> --- In email@example.com, "joy8388608" <mycroftj@> wrote:
> > Why does the semicolon in %SearchString% (after :,.) cause
> > an error on the SetListDelimiter statement?
> The error I see single stepping is a regex error, not an error on the SetListDelimiter statement.
> The problem is in NoteTab's parsing of the ^$GetDocMatchAll$ function which follows the SetListDelimiter statement. That function has an optional second parameter, and the second parameter follows a semicolon.
> If you include ;0 after the pattern in parameters for ^$GetDocMatchAll, it resolves. Zero is generally the default when the second parameter is omitted. Otherwise NoteTab splits the parameters at the semicolon and terminates the pattern portion early.
> Another issue with ^$GetDocMatchAll$ is sometimes seen when a pattern has ")$" in it -- NoteTab prematurely terminates the function. The solution for that one is to use the ^%dollar% instead of the dollar sign in the pattern.
> I noticed you didn't surround the string assigned to %SearchString% with double quotes. I would suggest to always use them. Use of double quotes sometimes avoids clipcode issues (but not in this case).
You showed me another thing I didn't know. I thought EVERYTHING after the equal sign in a SET statement was taken literally - even quotes but I see not. It wasn't until I put three together (Set %X%="""test""") that X was set to test with quotes. I don't remember reading about this. So what should be in quotes for a SET statement? Everything that is not a number???
It's a shame there isn't some central place for everyone to post notes and additional explanations for the help files. Yes, I'm sure keeping it all in order would be a big job. I know my notebook contains many notes like my new one on GetDocMatchAll and semicolons.
- I there something wrong with my mail display? I see no semicolon. I see a colon, a comma and a period.
> Why does the semicolon in %SearchString% (after :,.) cause
> an error on the SetListDelimiter statement?