Hi,
Great - I had missed out on the On Error Resume part in
my own testing.
Many thanks
Geoff
-----Original Message-----
Sub testIt()
Dim x As Name
On Error Resume Next
Set x = ActiveSheet.Names("myName")
On Error GoTo 0
MsgBox "Name myName exists: " & Not (x Is Nothing)
End Sub
--
Regards,
Tushar Mehta
www.tushar-mehta.com
Excel, PowerPoint, and VBA add-ins, tutorials
Custom MS Office productivity solutions
In article ,
says...
There are 2 named ranges, Quantity and Amount on
Sheet1.
Sheet1 is then copied 3 times (the same names are also
therefore copied).
If sheet5 is inserted (not copied) how can I
programatically detect if sheet5 has the named range
Quantity without the use of absolute cell references?
I'd be very grateful of advice.
Geoff
.