Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() i am running the following macro, Private Sub Worksheet_Change(ByVal Target As Range) If Range("FE11") = 1 Then MsgBox "VEHICLE MAY BE DUE FOR A SERVICE !!", vbBEEP + vbOKOnly End If End Sub i am a newbie to programming and can't figure out how to stop it from running everytime any cell value is changed in the worksheet other than "FE11" ! any help would be aprreciated thanks in advance bassfisher -- bassfisher ------------------------------------------------------------------------ bassfisher's Profile: http://www.excelforum.com/member.php...o&userid=27585 View this thread: http://www.excelforum.com/showthread...hreadid=472323 |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Add a line at the beginning:
If Intersect(Range("FE11"), Target) Is Nothing Then Exit Sub -- Vasant "bassfisher" wrote in message ... i am running the following macro, Private Sub Worksheet_Change(ByVal Target As Range) If Range("FE11") = 1 Then MsgBox "VEHICLE MAY BE DUE FOR A SERVICE !!", vbBEEP + vbOKOnly End If End Sub i am a newbie to programming and can't figure out how to stop it from running everytime any cell value is changed in the worksheet other than "FE11" ! any help would be aprreciated thanks in advance bassfisher -- bassfisher ------------------------------------------------------------------------ bassfisher's Profile: http://www.excelforum.com/member.php...o&userid=27585 View this thread: http://www.excelforum.com/showthread...hreadid=472323 |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Address(0,0) = "FE11" then if Range("FE11") = 1 Then MsgBox "VEHICLE MAY BE DUE FOR A SERVICE !!", vbBEEP + vbOKOnly End If End if End Sub -- Regards, Tom Ogilvy "bassfisher" wrote in message ... i am running the following macro, Private Sub Worksheet_Change(ByVal Target As Range) If Range("FE11") = 1 Then MsgBox "VEHICLE MAY BE DUE FOR A SERVICE !!", vbBEEP + vbOKOnly End If End Sub i am a newbie to programming and can't figure out how to stop it from running everytime any cell value is changed in the worksheet other than "FE11" ! any help would be aprreciated thanks in advance bassfisher -- bassfisher ------------------------------------------------------------------------ bassfisher's Profile: http://www.excelforum.com/member.php...o&userid=27585 View this thread: http://www.excelforum.com/showthread...hreadid=472323 |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() thanks for the advice, but it didn't solve the problem, now it appears as tho the macro stopped running. -- bassfisher ------------------------------------------------------------------------ bassfisher's Profile: http://www.excelforum.com/member.php...o&userid=27585 View this thread: http://www.excelforum.com/showthread...hreadid=472323 |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Did you disable macros when you opened the workbook?
Did you disable events while you were testing? bassfisher wrote: thanks for the advice, but it didn't solve the problem, now it appears as tho the macro stopped running. -- bassfisher ------------------------------------------------------------------------ bassfisher's Profile: http://www.excelforum.com/member.php...o&userid=27585 View this thread: http://www.excelforum.com/showthread...hreadid=472323 -- Dave Peterson |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() hello dave, no macros are enabled and i am sure the events are on, think, not sure! so much to learn! so little time! bassfishe -- bassfishe ----------------------------------------------------------------------- bassfisher's Profile: http://www.excelforum.com/member.php...fo&userid=2758 View this thread: http://www.excelforum.com/showthread.php?threadid=47232 |
#7
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Does this: "no macros are enabled" mean that macros are disabled?
If yes, set the security to medium and reopen your workbook and allow macros to run. (I didn't think that was the problem...) And you're sure the code is under the correct worksheet??? bassfisher wrote: hello dave, no macros are enabled and i am sure the events are on, i think, not sure! so much to learn! so little time! bassfisher -- bassfisher ------------------------------------------------------------------------ bassfisher's Profile: http://www.excelforum.com/member.php...o&userid=27585 View this thread: http://www.excelforum.com/showthread...hreadid=472323 -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
I AM TRYING TO STOP BEING PROMPTED TO SAVE EVERYTIME I USE EXCEL | Excel Worksheet Functions | |||
How to stop running macros everytime I run excel? | Excel Discussion (Misc queries) | |||
Password Prompt Everytime a Link is Changed | Excel Discussion (Misc queries) | |||
How do I stop dates from being entered everytime I enter a number | Excel Discussion (Misc queries) | |||
Automaticlly Running Macro on Changed Cell | Excel Programming |