ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   .OnEntry Macro does not fire when pasting (https://www.excelbanter.com/excel-programming/410532-onentry-macro-does-not-fire-when-pasting.html)

David

.OnEntry Macro does not fire when pasting
 
Is there a macro similar to the .onentry macro that will fire when a
value is pasted into the cell, rather than entered in. Alternatively
is there a way to make the .onentry macro fire when a value is pasted
into a cell.

TIA

David

T Lavedas

.OnEntry Macro does not fire when pasting
 
On May 6, 10:18 am, David wrote:
Is there a macro similar to the .onentry macro that will fire when a
value is pasted into the cell, rather than entered in. Alternatively
is there a way to make the .onentry macro fire when a value is pasted
into a cell.

TIA

David


Look into the Worksheet_Change event. Quoting the example in the
Excel VBA Help ...

Private Sub Worksheet_Change(ByVal Target as Range)
Target.Font.ColorIndex = 5
End Sub

It fires when a cell or range of cells changes because of entry or
other user activity; such as a Paste, drag and drop, deletion, etc.

Tom Lavedas
===========
http://members.cox.net/tglbatch/wsh/


All times are GMT +1. The time now is 10:13 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com