Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Program the paste event

Status
Not open for further replies.

EricsonJ

Programmer
Mar 3, 2002
44
0
0
US
What I want to to is to do something if the user has pressed ctrl-V. I would like to know what event is triggered after the user press ctrl-V.

Thanks
 

As far as I know, there is no such event in any Office application although most apps have a way of trapping most things - which one are you using and what, exactly, are you trying to intercept - might, say, disabling Copy be as effective as trapping Paste?

Enjoy,
Tony

--------------------------------------------------------------------------------------------
We want to help you; help us to do it by reading this: Before you ask a question.
Excel VBA Training and more Help at VBAExpress[
 
Thank you very much for your reply.

What I want to do is to calculate the values of some other cells according to what the user has pasted.

 
Hi EricsonJ,

Excel, OK.

Do you want these calculations done only when values are pasted in? Or when they are typed as well?

If the (unusual) former, it's going to be quite tricky.

If the latter then why not just have formulae in the other cells? If you really must run code then look at the Worksheet Change Event.



Enjoy,
Tony

--------------------------------------------------------------------------------------------
We want to help you; help us to do it by reading this: Before you ask a question.
Excel VBA Training and more Help at VBAExpress[
 
My case is the first one. But use formulae is a great idea. I tried it and it works.

I am a beginner in Excel programming. THank you so much.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top