Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Worksheet_Change event

Target, an argument in the worksheet_Change event holds a reference to what
has changed.

Right click on the sheet tab and select view code. Put in code like this:

Private Sub Worksheet_Change(ByVal Target As Range)
MsgBox Target.Address
End Sub

Then play around with your sheet.

--
Regards,
Tom Ogilvy






"TimD" wrote in message
...
I am using the Worksheet_Change event to manipulate data on a sheet.

Can I capture the event that has caused a change to the worksheet. Like
the
difference between deleting an entire row and deleting a specified range.




  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7,247
Default Worksheet_Change event

There is no way to determine whether the Change event was caused by VBA or
by the user. Your code should be written so that it doesn't matter.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com
(email address is on the web site)


"TimD" wrote in message
...
I am currently using the target object. I have drilled down into many of
it's
properies. I am not finding anything that looks like what event caused
target
to change.

"Tom Ogilvy" wrote:

Target, an argument in the worksheet_Change event holds a reference to
what
has changed.

Right click on the sheet tab and select view code. Put in code like
this:

Private Sub Worksheet_Change(ByVal Target As Range)
MsgBox Target.Address
End Sub

Then play around with your sheet.

--
Regards,
Tom Ogilvy






"TimD" wrote in message
...
I am using the Worksheet_Change event to manipulate data on a sheet.

Can I capture the event that has caused a change to the worksheet. Like
the
difference between deleting an entire row and deleting a specified
range.







Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Worksheet_change event. Mike K Excel Programming 8 October 24th 04 09:00 PM
Worksheet_change event Dwayne Smith Excel Programming 2 June 5th 04 03:25 AM
Worksheet_Change Event cmcfalls[_4_] Excel Programming 3 April 12th 04 09:47 PM
Worksheet_Change Event Sam Excel Programming 2 November 21st 03 06:51 PM
Worksheet_Change Event Not Working Michael Beckinsale Excel Programming 0 August 1st 03 02:43 PM


All times are GMT +1. The time now is 08:41 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"