Hi,
I want to check whether the ActiveCell is within a specific range. so when
using the Change function I would know whether to handle it or not.
How can I check if the target cell or the ActiveCell is within a certain
range?
Hi,
I want to check whether the ActiveCell is within a specific range. so when
using the Change function I would know whether to handle it or not.
How can I check if the target cell or the ActiveCell is within a certain
range?
Use the Intersect function.
Steve
"Yossi" <Yossi@discussions.microsoft.com> wrote in message
news:2849894E-C01E-4E9D-AF9D-E19339FCB062@microsoft.com...
> Hi,
> I want to check whether the ActiveCell is within a specific range. so when
> using the Change function I would know whether to handle it or not.
> How can I check if the target cell or the ActiveCell is within a certain
> range?
This kind of thing checks for changes to exactly one cell in A1:B99.
If target.cells.count > 1 then exit sub
if intersect(target,me.range("a1:B99")) is nothing then exit sub
'your code to do the work
Yossi wrote:
>
> Hi,
> I want to check whether the ActiveCell is within a specific range. so when
> using the Change function I would know whether to handle it or not.
> How can I check if the target cell or the ActiveCell is within a certain
> range?
--
Dave Peterson
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks