ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Cell Change (https://www.excelbanter.com/excel-programming/280202-cell-change.html)

timO

Cell Change
 
Hello All,
I would like a macro I wrote (text-to-columns) to run
after I input data into a particular cell.

Is there a way to set up my sheet to perform the
operation after I input the data.

Also is there a way to defeat the message box that
asks "Do you want to replace teh contents of the
destination cells?"

Thanks in advance

Tom Ogilvy

Cell Change
 
Use the Worksheet_Change event and test for that particular cell

Right click on the sheet tab, select view code. Put in code like this:

Private Sub Worksheet_Change(ByVal Target As Excel.Range)
If target.count 1 then exit sub
if Target.Address = "$B$1" then
' call your sub
End if
End Sub

--
Regards,
Tom Ogilvy


timO wrote in message
...
Hello All,
I would like a macro I wrote (text-to-columns) to run
after I input data into a particular cell.

Is there a way to set up my sheet to perform the
operation after I input the data.

Also is there a way to defeat the message box that
asks "Do you want to replace teh contents of the
destination cells?"

Thanks in advance





All times are GMT +1. The time now is 09:56 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com