Topic: Searching with a pattern set (1 of 2), Read 18 times
Conf: VEDIT Macro Language Support
From: Peter Rejto
Date: Sunday, June 19, 2011 06:06 PM

Hi,

I would like to perform a search with a pattern set.
According to Appendix F of the Macro Language Manual,

|{set} Matches one occurrence of any item in the “pattern set”.


So let S_1 and S_2 be two given strings. I did succeed in searching for any of these two strings. I typed

Search("S_1") and Search("S_2")

This worked like a charm.


However, I can not search for either of these two strings !


I thought that defining my pattern set to be,

{S_1,S_2}

and typing


Search("|{S_1,S_2}")

would do the job. However, I get a BAD PARAMETER error message.


I have a hunch that I am missing something simple. But I can not figure it out.



Thanks,

-peter

 


Topic: Searching with a pattern set (2 of 2), Read 16 times
Conf: VEDIT Macro Language Support
From: Peter Rejto
Date: Monday, June 20, 2011 12:32 AM

Hi,

I just noticed that my pattern set was perfectly OK.

My problem was that I was placing my delimiters at the wrong places.

Sorry for the confusion.

-peter