View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
davegb davegb is offline
external usenet poster
 
Posts: 573
Default Not understanding If Not..Then nothing

Here's my code:

'Test for Client Disab
On Error Resume Next
RecSht.Range("1:1").Select
FoundCell = Cells.find(What:="Client Disab", After:=ActiveCell,
LookIn:=xlFormulas, _
LookAt:=xlPart, SearchOrder:=xlByRows, SearchDirection:=xlNext,
_
MatchCase:=False)

If Not FoundCell Is Nothing Then
RecSht.Range("aa4").Copy Destination:=CtyExtr.Range("N5")

I've done a watch on "FoundCell", dimmed as range,on datasheets with
and without the searched for text ("Client Disab"). Whether the text is
found or not, FoundCell is nothing.
Any suggestions?