Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 661
Default On Error Goto doesn't goto

My "On Error goto" isn't working.

The following is a simple search. The search doesn't find the desired "2" so
it should go to EEERRR, but it doesn't; it gives an error message:

"Object variable or With block variable not set".

Any clue as to what that error message means?

Sub test2()
On error goto EEERRR

CCC = 2
Range("a10").Select
Cells.Find(What:=CCC, After:=ActiveCell, LookIn:= _
xlFormulas, LookAt:=xlPart, SearchOrder:=xlByRows, SearchDirection:= _
xlNext, MatchCase:=False).Select

EEERRR:
'some code here
End Sub

TIA!
Paul
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
On Error GoTo Doesn't Work [email protected] Excel Discussion (Misc queries) 2 November 29th 07 09:43 PM
On Error GoTo StanJ[_2_] Excel Programming 1 July 31st 04 06:15 PM
On Error GoTo : How to use multiple? e18 Excel Programming 8 May 17th 04 11:41 PM
On error goto 0? Brian Tozer Excel Programming 10 December 29th 03 09:59 PM
On error goto 0 David Excel Programming 2 November 18th 03 01:43 PM


All times are GMT +1. The time now is 10:38 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"