Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hello there,
I need to react to the data that a user may enter into certain cells (XL XP). How can I programmatically catch the entry that has been made ? Help greatly appreciated. Kind regards, H.G. Lamy |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
HG,
You need the Worksheet_Change event. You test for what has been entered by testing the Target argument. For instance, if you want to react to all changes in column N, use If Target.Column = 14 Then If you want to test for cells B5:G7 say, use If (Not Intersect(Target,Range("B5:G7")) Is Nothing) Then and then do your stuff. As this is worksheet code, it goes into the worksheet code module. -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "hglamy" wrote in message ... Hello there, I need to react to the data that a user may enter into certain cells (XL XP). How can I programmatically catch the entry that has been made ? Help greatly appreciated. Kind regards, H.G. Lamy |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Use the Change event procedure in the Sheet's code module. E.g.,
Private Sub Worksheet_Change(ByVal Target As Range) Select Case Target.Address Case "$A$1", "$B$2", "$C$3" MsgBox "You changed one of these cells" Case Else MsgBox "You changed cell " & Target.Address End Select End Sub -- Cordially, Chip Pearson Pearson Software Consulting, LLC Microsoft MVP - Excel www.cpearson.com "hglamy" wrote in message ... Hello there, I need to react to the data that a user may enter into certain cells (XL XP). How can I programmatically catch the entry that has been made ? Help greatly appreciated. Kind regards, H.G. Lamy |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thank you !
I had tried to work with the "Selection_Change" event, but with "Worksheet_Change" you pointed me to the right direction ! Kind regards, H.G. Lamy "hglamy" schrieb im Newsbeitrag ... Hello there, I need to react to the data that a user may enter into certain cells (XL XP). How can I programmatically catch the entry that has been made ? Help greatly appreciated. Kind regards, H.G. Lamy |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
LOCK CELL AFTER DATA IS ENTERED | Excel Discussion (Misc queries) | |||
Change color of cell when different cell has data entered | Excel Discussion (Misc queries) | |||
How do I get data automatically entered into a cell? | Excel Worksheet Functions | |||
data changes when entered into a cell | Excel Worksheet Functions | |||
Lock Data in Cell after entered | Excel Discussion (Misc queries) |