You can make all text comparisons in a module ignore case by placing
Option Compare Text
at the top of the module (above and outside of any procedure or
variable declarations). Or, you can ignore case with StrComp
If StrComp(string1, string2, vbTextCompare) = 0 Then
' strings are equal
Else
' strings are different
End If
Cordially,
Chip Pearson
Microsoft Most Valuable Professional
Excel Product Group, 1998 - 2009
Pearson Software Consulting, LLC
www.cpearson.com
(email on web site)
On Thu, 9 Apr 2009 12:33:02 -0700, dawall33
<(E-Mail Removed)> wrote:
>When I compare cell a1 to b1 in a formula capitalization is ignored, (ie. 2a
>= 2A). This same check in a VB script fails. I'm trying to create a sheet
>based of a text box and my check against the names passes but I get an error
>trying to name the new sheet with the capitalized version of the name.
>
>Ideas?