Page 1 of 1

hpwControl hpwExecRegExpPos Regex Error

PostPosted: Wed Jul 12, 2017 11:18 am
by tjchan
Hello!

I'm using this this entry that shows working in RegExBuddy:

Code: Select all
11-11-101011-(?:(?!\r).)*


The error that I am getting is:
TRegExpr(comp) Unrecognized Modifier (pos 21)

My NeoBook Code is:

Code: Select all
hpwExecRegExpPos "11-11-101011-(?:(?!\r).)*" "[data]" "[resultLocation]"


RegExBuddy is highlighting these entries for the following RegEx Code:
Code: Select all
11-11-101011-23201,972-111-6195,"AB220a-EGG, DAN", $1.00 ,DIGITAL - 12 BUTTON,,,
11-11-101011-23201,972-589-6364,"AB200-SUPER, AGENT", $1.00 ,DIGITAL - 30 BUTTON,,,
11-11-101011-23201,972-972-6384,"AB200-CHO, CHANG", $1.00 ,DIGITAL - 30 BUTTON,,,
11-11-101011-23201,972-238-6974,"AB218-JUDE, JANET", $1.00 ,DIGITAL - 30 BUTTON,,,


Thank you!
-Timothy

Re: hpwControl hpwExecRegExpPos Regex Error

PostPosted: Thu Jul 13, 2017 11:55 am
by HPW
Hello,

I am able to reproduce the problem on my side.
But I have no idea what the problem is.
The syntax option for Regex are often quite difficult to understand.
Therefor there exist this nice products like RegexBuddy and RegexMagic.
The used TRegexp is now quit outdated. Maybe a reason why it does not return the same as RegexBuddy,
One idea may be to ask the author of RegexBuddy what the problem could be. He is the real expert in this stuff.

Regards

Hans-Peter

Re: hpwControl hpwExecRegExpPos Regex Error

PostPosted: Thu Jul 13, 2017 12:15 pm
by mishem
HPW wrote:The syntax option for Regex are often quite difficult to understand.


This component does not understand:
(?=)
(?!)
(?<=)
(?<!)
(?>)
(?:)

Re: hpwControl hpwExecRegExpPos Regex Error

PostPosted: Fri Jul 14, 2017 6:07 am
by tjchan
Thanks a bunch! Will try to create a statement without those forbidden symbols. Thanks to both of you for your responses.