alaskanpilot
Board Regular
- Joined
- Sep 27, 2004
- Messages
- 104
Hi everyone,
I've found a few code snippets dealing with calling a Macro whenever a certain cell changes, but I cannot get any of them to work for me. I am wondering if my situation is a little different.
I have this code right now, placed into Sheet4:
I need the macro "LoadsheetConvert" to fire whenever cell W12 on Sheet4 has its value change. Cell W12 contains a formula, so its contents never change but it's value will. The formula in W12 refers to a named range. That formula, in case it matters, is
=LoadsheetChoice
which refers to a cell located on Sheet2.
Am I having issues because part of this process spills into another sheet? Is Excel perhaps not detecting changes in W12 because the formula in W12 does not change? I know that the macro I'm trying to call, is working, since I can manually make it run correctly. I've tried commenting out the EnableEvents lines to see if that was an issue, but it made no difference. I'm just puzzled here.
Thanks!
I've found a few code snippets dealing with calling a Macro whenever a certain cell changes, but I cannot get any of them to work for me. I am wondering if my situation is a little different.
I have this code right now, placed into Sheet4:
Code:
Private Sub Worksheet_Change(ByVal Target As Range)
Application.EnableEvents = False
If Not Intersect(Target, Target.Worksheet.Range("W12")) Is Nothing Then LoadsheetConvert
Application.EnableEvents = True
End Sub
I need the macro "LoadsheetConvert" to fire whenever cell W12 on Sheet4 has its value change. Cell W12 contains a formula, so its contents never change but it's value will. The formula in W12 refers to a named range. That formula, in case it matters, is
=LoadsheetChoice
which refers to a cell located on Sheet2.
Am I having issues because part of this process spills into another sheet? Is Excel perhaps not detecting changes in W12 because the formula in W12 does not change? I know that the macro I'm trying to call, is working, since I can manually make it run correctly. I've tried commenting out the EnableEvents lines to see if that was an issue, but it made no difference. I'm just puzzled here.
Thanks!