Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Worksheet_change
Hi
I wanted to have a worksheet change event whenever I change a cell in certain column (say column B) to something else the event would happen I figure this Private Sub Worksheet_Change(ByVal Target As Range) ???? If ????? and Target.Column = 2 then Application.EnableEvents = False Code, code End if Application.EnableEvents = True End Sub Thanks. B -- Message posted from http://www.ExcelForum.com |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Worksheet_change
How about:
Option Explicit Private Sub Worksheet_Change(ByVal Target As Range) If Target.Cells.Count 1 Then Exit Sub If Intersect(Target, Me.Range("b:b")) Is Nothing Then Exit Sub On Error GoTo errHandler: 'do lots of stuff Application.EnableEvents = False 'change some stuff. errHandler: Application.EnableEvents = True End Sub "rickey24 <" wrote: Hi I wanted to have a worksheet change event whenever I change a cell in a certain column (say column B) to something else the event would happen. I figure this Private Sub Worksheet_Change(ByVal Target As Range) ???? If ????? and Target.Column = 2 then Application.EnableEvents = False Code, code End if Application.EnableEvents = True End Sub Thanks. Bo --- Message posted from http://www.ExcelForum.com/ -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Sub Worksheet_Change | Excel Discussion (Misc queries) | |||
Worksheet_Change help | Excel Discussion (Misc queries) | |||
Worksheet_change won't run | Excel Discussion (Misc queries) | |||
worksheet_change vs. calculate, and worksheet_change not running | Excel Programming | |||
worksheet_change vs. calculate, and worksheet_change not running | Excel Programming |