View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
OZDOC1050[_3_] OZDOC1050[_3_] is offline
external usenet poster
 
Posts: 16
Default Make a cell in excel an object in VB

Private Sub Worksheet_Change(ByVal Target As Range)
Dim R As Range
Set R = Application.Intersect(Target, Range("F9:F15"))
If R Is Nothing Then Exit Sub
YOUR CODE HERE
End Sub

EDIT THE RANGE TO SUIT
R
PETE

--
(][ This Email has been scanned by Norton AntiVirus. ][)
"CTInt04" wrote in message
...
HI,

We would like to make a range of cells a single object so that when a

change is made only to one of those cells we can run an event procedure.
We are currently using the:

Private Sub Worksheet_Change function

But it runs the event procedure when you click anywhere on the sheet and

we only want it to run when a cell in the range is changed.

Is making a range of cells an object what we need to do in order to

accomplish this if so tell us how, if not do you have any other suggestions.


Thank you in advance,
CTInt04