Home |
Search |
Today's Posts |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Worksheet_Change should work fine.
With WorkBook_SheetChange the code runs every time you change ANY worksheet. Don. "Han" wrote in message ups.com... Thank you both for your input. I forgot that it's not Workbook_Change, but Workbook_SheetChange. Although, it does not explain why Worksheet_Change didn't do anything. No matter, I will be using the Workbook_SheetChange event. -------------------------------------------------------------------- Just in case someone reads this later on, the parameter "ByVal Sh As Object" is mandatory for the Workbook_SheetChange event. I receive a compile error if it is not included. My final working code looks like this: Private Sub Workbook_SheetChange(ByVal Sh As Object, ByVal Target As Range) If Target.Column < 19 Then Exit Sub If Cells(Target.Row, Target.Column).Value = "B" Then MsgBox "OMG! It works!" End If End Sub Once again, thank you for you input! |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Workbook_change event | Excel Discussion (Misc queries) | |||
Worksheet_change event. | Excel Programming | |||
Worksheet_change event | Excel Programming | |||
Worksheet_Change Event | Excel Programming | |||
Worksheet_Change Event | Excel Programming |