LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 361
Default Is there a way to run a procedure before the paste command?

I need to have a pop-up msg come up when someone tries to paste into a cell.
Is there a way to do this? I know how to create the pop-up, I just need to
know how to create the code to run when an attempt to paste is executed. I
created the following but the user has to double-click the cell and this is
not practical:

Private Sub Worksheet_BeforeDoubleClick( _
ByVal Target As Excel.Range, Cancel As Boolean)
With Target
If Application.CutCopyMode = False Then
Cancel = True
Else
Application.Run "PasteWarning"
End If
End With
End Sub

Thanks in advance, Carl
 
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
Simplify Command Button Procedure Kenny Excel Discussion (Misc queries) 2 October 14th 07 09:13 PM
Enable Command Button Procedure Kenny Excel Discussion (Misc queries) 1 October 14th 07 03:09 AM
UNIQ EXPEREINCE: PROCEDURE WORKS FINE USING F8 BUT GET ERROR WHEN COMMAND BUTTON IS CLICKED CAPTGNVR Excel Programming 1 July 6th 07 10:32 PM
How to elegantly end a main procedure from a userform command button? [email protected] Excel Programming 1 August 2nd 06 11:54 PM
Paste and Paste Special command are not enabled in Excel mcalder219 Excel Worksheet Functions 0 April 26th 06 06:57 PM


All times are GMT +1. The time now is 11:23 AM.

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

About Us

"It's about Microsoft Excel"