Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
just wondering, i have a calendar control that fires on B2. but i notice when stepping through the code after the date is entered, this code fires , even though it exits because the target cell is not being changed.
a lot of processing is done on this sheet and i'm wondering if this slows things down. -- Gary |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Gary,
The macro will be called for any worksheet change event but the amount of code execution is usually controlled at the start of the macro with something along the lines of If Target.Cells.Count 1 Or IsEmpty(Target) Then Exit Sub If Target.Address = "$B$2" Then This ends the macro for 3 most common you wouldn't want it it execute. 1. More than 1 cell selected 2. The target cell has no value in 3. It's not the intended target cell. Mike "Gary Keramidas" wrote: just wondering, i have a calendar control that fires on B2. but i notice when stepping through the code after the date is entered, this code fires , even though it exits because the target cell is not being changed. a lot of processing is done on this sheet and i'm wondering if this slows things down. -- Gary |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
i have all of that, i'm saying it exits without doing anything, but it's
processed thousands of times. just wondering if it slows the code down. -- Gary "Mike H" wrote in message ... Gary, The macro will be called for any worksheet change event but the amount of code execution is usually controlled at the start of the macro with something along the lines of If Target.Cells.Count 1 Or IsEmpty(Target) Then Exit Sub If Target.Address = "$B$2" Then This ends the macro for 3 most common you wouldn't want it it execute. 1. More than 1 cell selected 2. The target cell has no value in 3. It's not the intended target cell. Mike "Gary Keramidas" wrote: just wondering, i have a calendar control that fires on B2. but i notice when stepping through the code after the date is entered, this code fires , even though it exits because the target cell is not being changed. a lot of processing is done on this sheet and i'm wondering if this slows things down. -- Gary |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Maybe you want a worksheet_change event which fires when you change the cell instead of selecting it
-- Don Guillett Microsoft MVP Excel SalesAid Software "Gary Keramidas" <GKeramidasATmsn.com wrote in message ... just wondering, i have a calendar control that fires on B2. but i notice when stepping through the code after the date is entered, this code fires , even though it exits because the target cell is not being changed. a lot of processing is done on this sheet and i'm wondering if this slows things down. -- Gary |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
i want the calendar to pop up when the cell is clicked. but i've already deleted it, probably more trouble than it's worth.
thanks, don. -- Gary "Don Guillett" wrote in message ... Maybe you want a worksheet_change event which fires when you change the cell instead of selecting it -- Don Guillett Microsoft MVP Excel SalesAid Software "Gary Keramidas" <GKeramidasATmsn.com wrote in message ... just wondering, i have a calendar control that fires on B2. but i notice when stepping through the code after the date is entered, this code fires , even though it exits because the target cell is not being changed. a lot of processing is done on this sheet and i'm wondering if this slows things down. -- Gary |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Worksheet_SelectionChange Question | Excel Programming | |||
Worksheet_SelectionChange | Excel Programming | |||
Worksheet_SelectionChange | Excel Programming | |||
Worksheet_SelectionChange | Excel Programming | |||
Worksheet_SelectionChange | Excel Programming |