View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Ron Rosenfeld Ron Rosenfeld is offline
external usenet poster
 
Posts: 5,651
Default Help !, to find last 'text' date in text string

On Fri, 7 Apr 2006 12:59:23 -0500, jay
wrote:


Ron,

You've done some marvelous work here and I truly appreciate it.

However, when I attempt to run the macro I get a pop-up error window
of:

(Microsoft Visual Basic)
"Compiler error:"
"User defined type, not defined"

It occurs on the line of:

Dim objRegExp As RegExp - wherein the line is colored BLUE

However, the lines above it are colored yellow, which a

Function RECount(str As String, Pattern As String, _
Optional CaseSensitive As Boolean = True) As Long


QUESTION:
Did I do something wrong in my paste of the code ?

I'm using Windows2000 Professional
and Excel 2002 w/SP3

Thanks for all your help,


Your code pasting is probably OK.

I believe you overlooked the part of my instructions to set a reference to
vbscript:

---------------------------------------
My suggestion would be to set a reference (Tools/References) to

Microsoft VBScript Regular Expressions 5.5
--------------------------------------

On the menu bar at the top of the VBEditor, you will see an option "Tools".

Select this and then "References" from the drop-down menu. In there you will
see the above named reference. Place a check mark in the box next to it and
all should be well.

--ron