![]() |
Search and replace stuck on
I have never run into anything like this,
I looked into excels help on programming find and replace functionality, they offer the following code: With Worksheets(1).Range("a1:a500") Set c = .Find(2, lookin:=xlValues) If Not c Is Nothing Then firstAddress = c.Address Do c.Value = 5 Set c = .FindNext(c) Loop While Not c Is Nothing And c.Address < firstAddress End If End With I put a couple 2's in column a and ran and everything was fine. Went to work with thoughts of how to put this to use in my head and when I got home needed to type up a spreadsheet for work. Now whenever I typed a 2 it changed to a 5, I threw away the old Excel spreadsheet earlier and deleted it. Any clue on how to stop this would be greatly appreciated. -John |
Search and replace stuck on
Thanks but that workbook is long gone, it is still doing it on all my
workbooks, its even changing it as i type, if i put =2+2 the answer is 10. It never stopped running once I shut down, deleted and reset my computer. I've read before that Excel saves some features of how you search but I've got no clue "Don Guillett" wrote: Sounds like you put the code into a worksheet_change event that fires when you change a cell that is not restricted. The line c.Value = 5 is doing exactly what was asked of it. The code example was just that. An example. -- Don Guillett SalesAid Software "John Bundy" wrote in message ... I have never run into anything like this, I looked into excels help on programming find and replace functionality, they offer the following code: With Worksheets(1).Range("a1:a500") Set c = .Find(2, lookin:=xlValues) If Not c Is Nothing Then firstAddress = c.Address Do c.Value = 5 Set c = .FindNext(c) Loop While Not c Is Nothing And c.Address < firstAddress End If End With I put a couple 2's in column a and ran and everything was fine. Went to work with thoughts of how to put this to use in my head and when I got home needed to type up a spreadsheet for work. Now whenever I typed a 2 it changed to a 5, I threw away the old Excel spreadsheet earlier and deleted it. Any clue on how to stop this would be greatly appreciated. -John |
Search and replace stuck on
What you experiencing should not be happening.
Did you somehow create an Application.Event? Was your code in a class module or in the ThisWorkbook module? In any case, I would try to stop it by creating and running a sub / function using the old procedure name and setting c to Nothing and FirstAddress equal to vbNullString. -- Jim Cone San Francisco, USA http://www.realezsites.com/bus/primitivesoftware "John Bundy" wrote in message ... Thanks but that workbook is long gone, it is still doing it on all my workbooks, its even changing it as i type, if i put =2+2 the answer is 10. It never stopped running once I shut down, deleted and reset my computer. I've read before that Excel saves some features of how you search but I've got no clue "Don Guillett" wrote: Sounds like you put the code into a worksheet_change event that fires when you change a cell that is not restricted. The line c.Value = 5 is doing exactly what was asked of it. The code example was just that. An example. -- Don Guillett SalesAid Software "John Bundy" wrote in message ... I have never run into anything like this, I looked into excels help on programming find and replace functionality, they offer the following code: With Worksheets(1).Range("a1:a500") Set c = .Find(2, lookin:=xlValues) If Not c Is Nothing Then firstAddress = c.Address Do c.Value = 5 Set c = .FindNext(c) Loop While Not c Is Nothing And c.Address < firstAddress End If End With I put a couple 2's in column a and ran and everything was fine. Went to work with thoughts of how to put this to use in my head and when I got home needed to type up a spreadsheet for work. Now whenever I typed a 2 it changed to a 5, I threw away the old Excel spreadsheet earlier and deleted it. Any clue on how to stop this would be greatly appreciated. -John |
Search and replace stuck on
Thanks, but no good, any way to repair or re-install?
"Jim Cone" wrote: What you experiencing should not be happening. Did you somehow create an Application.Event? Was your code in a class module or in the ThisWorkbook module? In any case, I would try to stop it by creating and running a sub / function using the old procedure name and setting c to Nothing and FirstAddress equal to vbNullString. -- Jim Cone San Francisco, USA http://www.realezsites.com/bus/primitivesoftware "John Bundy" wrote in message ... Thanks but that workbook is long gone, it is still doing it on all my workbooks, its even changing it as i type, if i put =2+2 the answer is 10. It never stopped running once I shut down, deleted and reset my computer. I've read before that Excel saves some features of how you search but I've got no clue "Don Guillett" wrote: Sounds like you put the code into a worksheet_change event that fires when you change a cell that is not restricted. The line c.Value = 5 is doing exactly what was asked of it. The code example was just that. An example. -- Don Guillett SalesAid Software "John Bundy" wrote in message ... I have never run into anything like this, I looked into excels help on programming find and replace functionality, they offer the following code: With Worksheets(1).Range("a1:a500") Set c = .Find(2, lookin:=xlValues) If Not c Is Nothing Then firstAddress = c.Address Do c.Value = 5 Set c = .FindNext(c) Loop While Not c Is Nothing And c.Address < firstAddress End If End With I put a couple 2's in column a and ran and everything was fine. Went to work with thoughts of how to put this to use in my head and when I got home needed to type up a spreadsheet for work. Now whenever I typed a 2 it changed to a 5, I threw away the old Excel spreadsheet earlier and deleted it. Any clue on how to stop this would be greatly appreciated. -John |
Search and replace stuck on
try
toolsauto correct optionsscroll down the list to see if you have a replace 2 with 5 if so delete -- Don Guillett SalesAid Software "John Bundy" wrote in message ... Thanks, but no good, any way to repair or re-install? "Jim Cone" wrote: What you experiencing should not be happening. Did you somehow create an Application.Event? Was your code in a class module or in the ThisWorkbook module? In any case, I would try to stop it by creating and running a sub / function using the old procedure name and setting c to Nothing and FirstAddress equal to vbNullString. -- Jim Cone San Francisco, USA http://www.realezsites.com/bus/primitivesoftware "John Bundy" wrote in message ... Thanks but that workbook is long gone, it is still doing it on all my workbooks, its even changing it as i type, if i put =2+2 the answer is 10. It never stopped running once I shut down, deleted and reset my computer. I've read before that Excel saves some features of how you search but I've got no clue "Don Guillett" wrote: Sounds like you put the code into a worksheet_change event that fires when you change a cell that is not restricted. The line c.Value = 5 is doing exactly what was asked of it. The code example was just that. An example. -- Don Guillett SalesAid Software "John Bundy" wrote in message ... I have never run into anything like this, I looked into excels help on programming find and replace functionality, they offer the following code: With Worksheets(1).Range("a1:a500") Set c = .Find(2, lookin:=xlValues) If Not c Is Nothing Then firstAddress = c.Address Do c.Value = 5 Set c = .FindNext(c) Loop While Not c Is Nothing And c.Address < firstAddress End If End With I put a couple 2's in column a and ran and everything was fine. Went to work with thoughts of how to put this to use in my head and when I got home needed to type up a spreadsheet for work. Now whenever I typed a 2 it changed to a 5, I threw away the old Excel spreadsheet earlier and deleted it. Any clue on how to stop this would be greatly appreciated. -John |
Search and replace stuck on
Don, you are the MAN!!about 30 years of combined experience couldn't figure
that out, i'm going to see how long it takes them :) Thanks again "Don Guillett" wrote: try toolsauto correct optionsscroll down the list to see if you have a replace 2 with 5 if so delete -- Don Guillett SalesAid Software "John Bundy" wrote in message ... Thanks, but no good, any way to repair or re-install? "Jim Cone" wrote: What you experiencing should not be happening. Did you somehow create an Application.Event? Was your code in a class module or in the ThisWorkbook module? In any case, I would try to stop it by creating and running a sub / function using the old procedure name and setting c to Nothing and FirstAddress equal to vbNullString. -- Jim Cone San Francisco, USA http://www.realezsites.com/bus/primitivesoftware "John Bundy" wrote in message ... Thanks but that workbook is long gone, it is still doing it on all my workbooks, its even changing it as i type, if i put =2+2 the answer is 10. It never stopped running once I shut down, deleted and reset my computer. I've read before that Excel saves some features of how you search but I've got no clue "Don Guillett" wrote: Sounds like you put the code into a worksheet_change event that fires when you change a cell that is not restricted. The line c.Value = 5 is doing exactly what was asked of it. The code example was just that. An example. -- Don Guillett SalesAid Software "John Bundy" wrote in message ... I have never run into anything like this, I looked into excels help on programming find and replace functionality, they offer the following code: With Worksheets(1).Range("a1:a500") Set c = .Find(2, lookin:=xlValues) If Not c Is Nothing Then firstAddress = c.Address Do c.Value = 5 Set c = .FindNext(c) Loop While Not c Is Nothing And c.Address < firstAddress End If End With I put a couple 2's in column a and ran and everything was fine. Went to work with thoughts of how to put this to use in my head and when I got home needed to type up a spreadsheet for work. Now whenever I typed a 2 it changed to a 5, I threw away the old Excel spreadsheet earlier and deleted it. Any clue on how to stop this would be greatly appreciated. -John |
Search and replace stuck on
Glad to help.
-- Don Guillett SalesAid Software "John Bundy" wrote in message ... Don, you are the MAN!!about 30 years of combined experience couldn't figure that out, i'm going to see how long it takes them :) Thanks again "Don Guillett" wrote: try toolsauto correct optionsscroll down the list to see if you have a replace 2 with 5 if so delete -- Don Guillett SalesAid Software "John Bundy" wrote in message ... Thanks, but no good, any way to repair or re-install? "Jim Cone" wrote: What you experiencing should not be happening. Did you somehow create an Application.Event? Was your code in a class module or in the ThisWorkbook module? In any case, I would try to stop it by creating and running a sub / function using the old procedure name and setting c to Nothing and FirstAddress equal to vbNullString. -- Jim Cone San Francisco, USA http://www.realezsites.com/bus/primitivesoftware "John Bundy" wrote in message ... Thanks but that workbook is long gone, it is still doing it on all my workbooks, its even changing it as i type, if i put =2+2 the answer is 10. It never stopped running once I shut down, deleted and reset my computer. I've read before that Excel saves some features of how you search but I've got no clue "Don Guillett" wrote: Sounds like you put the code into a worksheet_change event that fires when you change a cell that is not restricted. The line c.Value = 5 is doing exactly what was asked of it. The code example was just that. An example. -- Don Guillett SalesAid Software "John Bundy" wrote in message ... I have never run into anything like this, I looked into excels help on programming find and replace functionality, they offer the following code: With Worksheets(1).Range("a1:a500") Set c = .Find(2, lookin:=xlValues) If Not c Is Nothing Then firstAddress = c.Address Do c.Value = 5 Set c = .FindNext(c) Loop While Not c Is Nothing And c.Address < firstAddress End If End With I put a couple 2's in column a and ran and everything was fine. Went to work with thoughts of how to put this to use in my head and when I got home needed to type up a spreadsheet for work. Now whenever I typed a 2 it changed to a 5, I threw away the old Excel spreadsheet earlier and deleted it. Any clue on how to stop this would be greatly appreciated. -John |
All times are GMT +1. The time now is 10:09 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com