This actually pertains to Visual Basic for Application in Access 2003, but I imagine that this forum should yield accurate information for a simple query such as this.
Naturally, the event in the title does not exist. Not for the pre-defined text box control in VB, anyway. However, it is what I'd like to capture.
I have a database that end-users use along side of a mainframe system. A few of the controls in the database forms contain fields that are more readable in one format, but required in another format for input into the mainframe. For example, an account number.
These fields contain dashes ("-") in order to make them more pleasing to the eye, however, when they copy the account and paste it into the mainframe, they can't have the dashes. So, I would like that if I have a field showing "123-45678-90", it would copy "1234567890".
This is easy enough to capture if the user uses Ctrl+C to copy. I'd imagine I could pick that up in the keypress event of the control, pull the clipboard, remove the dashes, and reapply. I don't know how to capture the event that the user highlights, right-clicks, and selects "Copy" from the menu. I considered the possibility of disabling this feature and implementing my own copy button (which would either be in the right-click list if I can add things to it or in an application menu above the form which I know I can do. I'm hoping, however, there is a way to actually capture the copy event, though.
So does anyone know a way to go about this?