Copy to clipboard stopped working.

B

bravofoxtrotuk

My database has several forms which have buttons for copying items to the
clipboard, using something like this:

me.txtEmail.SetFocus
' copy email details to clipboard
DoCmd.RunCommand acCmdCopy

- which worked fine for some years until this morning when a Micro$oft
update took place, and it stopped working.

I've changed the code as below:

Me.EMail.SetFocus
' now select the text
Me.EMail.SelStart = 0
Me.EMail.SelLength = Len(Me.EMail)

' copy email details to clipboard
DoCmd.RunCommand acCmdCopy


- and it now works again!

A co-incidence perhaps, and a mystery to me, but may help others.

Bob
 
B

bravofoxtrotuk

I've done some more checking since this post, and find it WAS a coincidence.
(sorry MS). The problem was a result of a user asking that the database
behaviour be changed around the same time, by altering Tools | Options |
Keyboard and changing 'Behavior entering field' to 'Go to start of field'
from 'Select entire field'.

However, the fix remains the same, so if copy to clipboard isn't working for
you it may be because of this.

Bob
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top