Re: regular expression doesn't detect set pattern

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



Here is more information on trying Regular Expressions in VBA:

http://www.j.nurick.dial.pipex.com/Code/index.htm

One downside is that they rely on VBScripting or Windows Scripting which
won't work in MacWord VBA.


Thanks for the suggestion, Russ. For searching, I use wildcards also but I
would like to use regular expressions since they're better for evaluating
(not searching for) text so that I don't have to do something like

If Selection=chr(13) or selection=chr(10)

if I don't know if the end-of-line character will be a soft or hard break. I
would prefer to take advantage of pattern matching rather than a specific
character. I've never been successful, for example, in writing

if selection="^p"

but I use ^p all the time for searching. If you know of a better way for
evaluating a selection, I'll readily welcome the suggestion.

--
Russ

drsmN0SPAMikleAThotmailD0Tcom.INVALID

.



Relevant Pages

  • Re: Enumerating Regular Expressions
    ... The power of regular expressions is that they define a consice means to encapsulate an infinite number of inputs. ... That said, unless you can ensure you don't have an infinite grammer, you then have the problem of how to navigate that infinite set. ... Do you begin searching depth-first with "a" and then "aa" and then "aaa"? ...
    (comp.lang.python)
  • Re: String splitten und Mail-Adresse extrahieren
    ... >"Microsoft VBScript Regular Expressions" Bibliothek einbinden. ... Hallo Klaus, ... deshalb gerade folgendes Problem in VBA: ... Next by Date: ...
    (microsoft.public.de.access)
  • Re: Inserting contents of Word document into a richtextbox control
    ... I am trying to do this from VBA - the versions of Word I'm using are ... > || richtextbox text as the activedocument contents but this is too clumsy ... After searching in groups I realised that Word doesn't use ... > || I even tried creating my own ActiveX control in VB but don't have the ...
    (microsoft.public.word.vba.general)
  • Re: Is there any regexp and hashtable management in Excel VBA?
    ... Use Regular Expressions in Microsoft Visual Basic 6.0 ... Should work for VBA as well. ... But the keyword "Regexp" is not available. ... resulting text from the hard disk. ...
    (microsoft.public.excel.programming)
  • Re: Great SWT Program
    ... Ah yes, again with the "if it isn't obvious to the novice, it doesn't ... Learning a bit about regular expressions and how ... Searching the documentation tends to be begging the ...
    (comp.lang.java.programmer)