Re: Need Regex help
Hello Januk, On Mittwoch, 14. November 2001 at 11:13:10 you wrote (at least in part): JA> It was meant as a joke, sorry if that wasn't clear. It was :-) But nevertheless I was ashamed my perfectionism stumbled over _this_ tiny cute quotation marks :-) -- Regards Peter Palmreuthermailto:[EMAIL PROTECTED] (The Bat! v1.54/10e on Windows NT 5.0 Build 2195 Service Pack 2) Does Your Spearmint Lose It's Flavor (on the Bedpost overnight)? -- __ Archives : http://tbtech.thebat.dutaint.com Moderators : mailto:[EMAIL PROTECTED] Unsubscribe: mailto:[EMAIL PROTECTED]
Re: Need Regex help
Hello Peter, Historians believe that Wednesday, November 14, 2001 at 09:40 GMT +0100 was when, Peter Palmreuther [PP] typed the following: JA>> Someone forgot their quotation marks. PP> *ashamed* .-( It was meant as a joke, sorry if that wasn't clear. But it did illuminate a new behaviour in TB. In previous versions, the missing quotation marks didn't always affect the outcome. Now, missing those quotation marks causes much bigger problems. -- Thanks for writing, Januk Aggarwal Using The Bat! 1.54/10 under Windows 98 4.10 Build A Have you ever imagined a world without hypothetical situations? -- __ Archives : http://tbtech.thebat.dutaint.com Moderators : mailto:[EMAIL PROTECTED] Unsubscribe: mailto:[EMAIL PROTECTED]
Re[2]: Need Regex help
Januk Aggarwal [JA], on Tuesday, November 13, 2001 at 23:44 (-0800) thoughtfully wrote the following: JA> %TO="[EMAIL PROTECTED]" JA> %TO='[EMAIL PROTECTED]' JA> [EMAIL PROTECTED] JA> The third one can be confusing to say the least, but it works. That JA> means that if you forget the quotation marks, TB will take the first JA> letter/character of your string and use that as the delimiter. This JA> can lead to some very unexpected results. Note: the rules governing JA> these new delimiters are the same as the traditional ones. For JA> example, if you want the character in your string, you must double it JA> up, etc. this is really funny. it is bug ?? -- --+ +-- +- WEB: www.2ge.skMail: [EMAIL PROTECTED] +--+ | - +--IRC: _2ge_ (ircnet)ICQ UIN: 7552083 ++==+=+- The Bat! 1.54/10 on Windows NT 2195.5.0 I'll have what the gentleman on the floor is havin -- __ Archives : http://tbtech.thebat.dutaint.com Moderators : mailto:[EMAIL PROTECTED] Unsubscribe: mailto:[EMAIL PROTECTED]
Re: Need Regex help
Hello Peter Palmreuther, Wednesday, November 14, 2001, 3:40:56 PM, you wrote to Januk Aggarwal on TBTECH: JA>> Someone forgot their quotation marks. > *ashamed* .-( However, thanks to you and Allie for your attention :-) -- Best regards, Syafrilmailto:[EMAIL PROTECTED] -- __ Archives : http://tbtech.thebat.dutaint.com Moderators : mailto:[EMAIL PROTECTED] Unsubscribe: mailto:[EMAIL PROTECTED]
Re: Need Regex help
Hello Januk, On Wednesday, 14. November 2001 at 08:17:04 you wrote (at least in part): JA> Someone forgot their quotation marks. *ashamed* .-( -- Regards Peter Palmreuthermailto:[EMAIL PROTECTED] (The Bat! v1.54/10e on Windows NT 5.0 Build 2195 Service Pack 1) Go Speed Racer Go Speed Racer Go Speed Racer Go -- __ Archives : http://tbtech.thebat.dutaint.com Moderators : mailto:[EMAIL PROTECTED] Unsubscribe: mailto:[EMAIL PROTECTED]
Re: Need Regex help
It was foretold that on Tuesday, November 13, 2001 at 11:17 PM, Januk Aggarwal [JA] would type: >>> %SUBPATT=1 JA> The problem isn't the regexp, it's the %SUBPATT macro. Someone forgot JA> their quotation marks. ;-) I should note, it seems TB's macro engine is a little more unpredictable than the help file would suggest. It would seem that TB looks at the first character after the = and uses that to be the argument delimiter. In other words, the following are equivalent: %TO="[EMAIL PROTECTED]" %TO='[EMAIL PROTECTED]' [EMAIL PROTECTED] The third one can be confusing to say the least, but it works. That means that if you forget the quotation marks, TB will take the first letter/character of your string and use that as the delimiter. This can lead to some very unexpected results. Note: the rules governing these new delimiters are the same as the traditional ones. For example, if you want the character in your string, you must double it up, etc. So be warned and be careful. -- Thanks for writing, Januk Aggarwal Using The Bat! 1.54/10 under Windows 98 4.10 Build A Despite these words, this page is blank. -- __ Archives : http://tbtech.thebat.dutaint.com Moderators : mailto:[EMAIL PROTECTED] Unsubscribe: mailto:[EMAIL PROTECTED]
Re: Need Regex help
Hello Januk Aggarwal, Wednesday, November 14, 2001, 2:17:04 PM, you wrote to Syafril Hermansyah: >>> <--> >>> Hello %- >>> %SETPATTREGEXP="(?m-s)^From:\s*(.*?)\s*<.*?@.*?>|^From:\s*<(.*?@.*?)>"%- >>> %REGEXPBLINDMATCH="%Text"%- >>> %SUBPATT=1 >^^^ SH>> Weird, still not work here. SH>> I attached one example, so you may tried with real things :-) > The problem isn't the regexp, it's the %SUBPATT macro. Someone forgot > their quotation marks. ;-) > Try this one: > %SETPATTREGEXP="(?m-s)^From:\s*(.*?)\s*\<.*?@.*?\>|^From:\s*\<(.*?@.*?)\>"%- > %REGEXPBLINDMATCH="%Text"%- > %SUBPATT="1" Yippe, it work! Thanks Januk -- Best regards, Syafrilmailto:[EMAIL PROTECTED] -- __ Archives : http://tbtech.thebat.dutaint.com Moderators : mailto:[EMAIL PROTECTED] Unsubscribe: mailto:[EMAIL PROTECTED]
Re: Need Regex help
Hi Syafril, An archeological dig discovered that on Wednesday, November 14, 2001 at 10:37 GMT +0700, Syafril Hermansyah [SH] typed the following: >> <--> >> Hello %- >> %SETPATTREGEXP="(?m-s)^From:\s*(.*?)\s*<.*?@.*?>|^From:\s*<(.*?@.*?)>"%- >> %REGEXPBLINDMATCH="%Text"%- >> %SUBPATT=1 ^^^ SH> Weird, still not work here. SH> I attached one example, so you may tried with real things :-) The problem isn't the regexp, it's the %SUBPATT macro. Someone forgot their quotation marks. ;-) Try this one: %SETPATTREGEXP="(?m-s)^From:\s*(.*?)\s*\<.*?@.*?\>|^From:\s*\<(.*?@.*?)\>"%- %REGEXPBLINDMATCH="%Text"%- %SUBPATT="1" -- Thanks for writing, Januk Aggarwal Using The Bat! 1.54/10 under Windows 98 4.10 Build A All science is either physics or stamp collecting. -- E. Rutherford -- __ Archives : http://tbtech.thebat.dutaint.com Moderators : mailto:[EMAIL PROTECTED] Unsubscribe: mailto:[EMAIL PROTECTED]
Re: Need Regex help
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 @ 15:57:59 +0100 [ Tue, 13 Nov 2001], Peter Palmreuther [PP] contributed this to our collective wisdom: ... PP> <--> PP> Hello %- PP> %SETPATTREGEXP="^From:\s*(.*?)\s*<.*?@.*?>|^From:\s*<(.*?@.*?)>"%- PP> %REGEXPBLINDMATCH="%Text"%- PP> %SUBPATT=1 PP> <--> The expression seems OK but I'd add option settings to make it like this: <--> Hello %- %SETPATTREGEXP="(?m-s)^From:\s*(.*?)\s*<.*?@.*?>|^From:\s*<(.*?@.*?)>"%- %REGEXPBLINDMATCH="%Text"%- %SUBPATT=1 <--> See if *that* works. - -- ©Allie C Martin -- List Moderator and fellow end-user PGPKey - mailto:[EMAIL PROTECTED]?Subject=PGPPubKey1 [MUA: TB! v1.54/10 (*) OS: Win2K SP 2] __ -BEGIN PGP SIGNATURE- Version: GnuPG v1.0.6 (MingW32) Comment: Sealed for Security iEYEARECAAYFAjvx2BQACgkQV8nrYCsHF+JJjgCg7wK9ylGVV+YRSeiaG8Kam+28 D5wAoIS+v64q7Z9xS+yD/uBlTxCXkUWE =gjvx -END PGP SIGNATURE- -- __ Archives : http://tbtech.thebat.dutaint.com Moderators : mailto:[EMAIL PROTECTED] Unsubscribe: mailto:[EMAIL PROTECTED]
Re: Need Regex help
Hello Peter Palmreuther, Tuesday, November 13, 2001, 10:29:55 PM, you wrote to Syafril Hermansyah on TBTECH: SH>> Ugh.. still not work, the result I only get "Hello" word only, no SH>> quote and others. SH>> Where am I wrong ? > I dunno where you're wrong :-) I can guess where I'm wrong :=) Ha..ha..ha... > Try this > <--> > Hello %- > %SETPATTREGEXP="From:\s*<(.*@.*)>|From:\s*(.+?)<.*@.*>"%- > %REGEXPBLINDMATCH="%Text"%- > %SUBPATT=1%SUBPATT=2%- > , > %QUOTES > <--> Still not work, same result :-( > One thing said before noticed by somebody else: the RegExp ain't very > fault tolerant right know and there's yet no solution for stripping > the 'From: ...' line from quoted material ... plus I don't know if it > works with Select+F4-Replying ... Not working too... -- Best regards, Syafrilmailto:[EMAIL PROTECTED] -- __ Archives : http://tbtech.thebat.dutaint.com Moderators : mailto:[EMAIL PROTECTED] Unsubscribe: mailto:[EMAIL PROTECTED]
Re: Need Regex help
Hello Syafril, On Tuesday, November 13, 2001 at 4:07:37 PM you wrote (at least in part): >> <--> >> Hello %- >> %SETPATTREGEXP="^From:\s*(.*?)\s*<.*?@.*?>|^From:\s*<(.*?@.*?)>"%- >> %REGEXPBLINDMATCH="%Text"%- >> %SUBPATT=1 >> <--> SH> Ugh.. still not work, the result I only get "Hello" word only, no SH> quote and others. SH> Where am I wrong ? I dunno where you're wrong :-) I can guess where I'm wrong :=) Try this <--> Hello %- %SETPATTREGEXP="From:\s*<(.*@.*)>|From:\s*(.+?)<.*@.*>"%- %REGEXPBLINDMATCH="%Text"%- %SUBPATT=1%SUBPATT=2%- , %QUOTES <--> One thing said before noticed by somebody else: the RegExp ain't very fault tolerant right know and there's yet no solution for stripping the 'From: ...' line from quoted material ... plus I don't know if it works with Select+F4-Replying ... Ciao Pit -- Regards Peter Palmreuthermailto:[EMAIL PROTECTED] (The Bat! v1.54/10 on Windows NT 5.0 Build 2195 Service Pack 2) All things being equal, a fat person uses more soap than a thin person. -- __ Archives : http://tbtech.thebat.dutaint.com Moderators : mailto:[EMAIL PROTECTED] Unsubscribe: mailto:[EMAIL PROTECTED]
Re: Need Regex help
Hello Syafril, On Tuesday, November 13, 2001 at 12:30:20 PM you wrote (at least in part): SH> I just want my greetings (reply Template) automatically put "Hello SH> "Author Real Name" on top of body text, is it possible to do that ? I think it should. I know pretty much about RegExp in general, I'll try to put it in TB! syntax which is still really ... different *g* ... to me :-) <--> Hello %- %SETPATTREGEXP="^From:\s*(.*?)\s*<.*?@.*?>|^From:\s*<(.*?@.*?)>"%- %REGEXPBLINDMATCH="%Text"%- %SUBPATT=1 <--> This is a quick-and-dirty-but-could-be-a-point-to-start-from RegExp that came to my mind in 30 seconds of thinking. It should match for a name or, if not present but only the e-mail-address, the whole e-mail-address without '<' & '>'. May the TB!-RegExp-Gurus kill me or correct me if I'm wrong :-) -- Regards Peter Palmreuthermailto:[EMAIL PROTECTED] (The Bat! v1.54/10 on Windows NT 5.0 Build 2195 Service Pack 2) Of all the things I lost, I miss my mind! -- __ Archives : http://tbtech.thebat.dutaint.com Moderators : mailto:[EMAIL PROTECTED] Unsubscribe: mailto:[EMAIL PROTECTED]