Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10
Default run macro whenever any cell is changed

I have a Validate macro in a spreadsheet that checks several fields whenever
the Validate macro button
is clicked. Is there a way to call that macro any time any cell in the sheet
is changed or selected. The
clerks can't seem to click the button when they access the sheet. One of the
import validation checks it
does is check the Contact time for all rows which alerts us if a Tech hasn't
touched base with us within
the last 2 hours if his job is still open.

Thanks in advance...


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,986
Default run macro whenever any cell is changed

Put your macro in the sheet module as a Worksheet_Change procedure by right
clicking the sheet tabViewCode. Click the window that says General, then
click worksheet. That should load the declarations window from which you can
select "Change" and that should then enter the following in the code module:

Private Sub Worksheet_Change(ByVal Target As Range)

End Sub

Enter your code between the two lines.

"bob engler" wrote:

I have a Validate macro in a spreadsheet that checks several fields whenever
the Validate macro button
is clicked. Is there a way to call that macro any time any cell in the sheet
is changed or selected. The
clerks can't seem to click the button when they access the sheet. One of the
import validation checks it
does is check the Contact time for all rows which alerts us if a Tech hasn't
touched base with us within
the last 2 hours if his job is still open.

Thanks in advance...



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
run macro automatically when cell content is changed? Kathrine Excel Worksheet Functions 1 March 22nd 07 10:44 PM
Run a macro when a cell is changed by an outside source Jon[_21_] Excel Programming 3 November 9th 05 06:26 PM
Run Macro when particular cell is changed? Dr.Ile Excel Programming 0 November 2nd 04 09:30 AM
Run Macro when particular cell is changed? mangesh_yadav[_153_] Excel Programming 0 November 2nd 04 09:21 AM
Run an excel macro when a cell value is changed VonnerNIX[_3_] Excel Programming 0 September 28th 04 02:17 PM


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

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

About Us

"It's about Microsoft Excel"