LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Macro works, then doesn't


Why does this code work one day, then the next it does not?
I have to write a new code every time I launch this WB WHY??

My security is set to LOW now, and trusted sources are both checked.
It ONLY happenes in this workbook, the codes work in others just fine, what
could be the problem with this workbook ( if the code is right?)
Thanks in advance if you can help.

Sub FindThis()
Dim rngToSearch As Range
Dim rngFound As Range
Dim wks As Worksheet
Set wks = ActiveSheet
Set rngToSearch = Worksheets("Schedule").Range("A4:A5205")
Set rngFound = rngToSearch.Find(What:=wks.Range("$A$1"), _
LookAt:=xlPart, MatchCase:=False)

If Not rngFound Is Nothing Then
Application.Goto Range(rngFound.Address), True


Else
MsgBox "Not Found"
End If
End Sub
 
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
Macro do works in excel... driller Excel Worksheet Functions 7 July 12th 07 02:56 PM
Macro works on one computer but not another Dagonini Excel Programming 3 February 21st 07 04:37 PM
Macro Only works Once [email protected] Excel Programming 8 December 28th 06 11:42 PM
Macro works once, not twice Madvark Excel Programming 6 June 18th 04 11:00 PM
macro works in .xlt but not .xls BrianG[_3_] Excel Programming 6 September 18th 03 10:13 PM


All times are GMT +1. The time now is 01:50 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"