How to use worksheet change code

CHERRYBERRY

New Member
Joined
May 31, 2012
Messages
29
I have to run macro when automatically when value of cell change automatically. My code works perfectly when i change the cell value manually.
 

Excel Facts

Does the VLOOKUP table have to be sorted?
No! when you are using an exact match, the VLOOKUP table can be in any order. Best-selling items at the top is actually the best.
Oops, I answered in the testing forum :(

Was the same as below anyway
 
Last edited:
Upvote 0
Actually i am monitoring the values of different machines. So as the value of machine changes. The cell value of my excel sheet automatically changes. I want to run mymacro when the value changes automatically
 
Upvote 0
Private Sub worksheet_calculate()




If Not Intersect(TARGET, RANGE("E31:H31")) Is Nothing And Cells(31, 6) > 8 Then
Application.EnableEvents = False
alarmsave
Application.EnableEvents = True
End If
END SUB
 
Upvote 0
There is no Target argument with that event. Try

Code:
If Cells(31, 6).VALUE > 8 Then
 
Upvote 0

Forum statistics

Threads
1,203,674
Messages
6,056,680
Members
444,881
Latest member
Stu2407

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top