Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Simple change event. Need guidance.
I want to run a simple If..Then based on a change to a range of cell
containing text. Basically something like this If Range("E50:E100") changes Then Range("A3") = Now() End if So if the text changes in the range the date of the document updates t the system date. Seems like it should be simple but I can't figure ou how to do it. Any help appreciated. Jakeste -- Message posted from http://www.ExcelForum.com |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Simple change event. Need guidance.
Hi
put the following code in your worksheet module: Private Sub Worksheet_Change(ByVal Target As Excel.Range) if target.cells.count1 then exit sub If Intersect(Range("E50:E100"), Target) Is Nothing Then Exit Sub on error goto errhandler With Target If .Value < "" Then Application.EnableEvents = False me.Range("A3").value=now me.Range("A3").numberformat="MM/DD/YYYY hh:mm" End If End With errhandler: Application.EnableEvents = True End Sub -- Regards Frank Kabel Frankfurt, Germany "Jakester " schrieb im Newsbeitrag ... I want to run a simple If..Then based on a change to a range of cells containing text. Basically something like this If Range("E50:E100") changes Then Range("A3") = Now() End if So if the text changes in the range the date of the document updates to the system date. Seems like it should be simple but I can't figure out how to do it. Any help appreciated. Jakester --- Message posted from http://www.ExcelForum.com/ |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Simple change event. Need guidance.
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Column = 5 _ And Target.Row = 50 _ And Target.Row <= 100 Then Range("A3") = Now() End If End Sub = Piku -- Message posted from http://www.ExcelForum.com |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Chart Values that change based on Change event | Excel Programming | |||
Need code for simple change event | Excel Programming | |||
Change minimumscale with the change event of a combobox | Excel Programming | |||
On change event | Excel Programming | |||
change event/after update event?? | Excel Programming |