AA Arens wrote:
I want Access copies the contents of the field "postal code" (like
12345) which is part of the same form as the button i want to make, to
launch an external applicaiton. I need the copied value in the external
application.
Bart
I created a form with 2 text boxes; Text0 and Text2. In the AfterUpdate
event of Text0 I entered the following code
Me.Text0.SelStart = 0
Me.Text0.SelLength = Len(Me.Text0)
DoCmd.RunCommand acCmdCopy
When I moved to Text2 I could do an edit/paste and the value I entered
in Text0 would be filled in.
If you were in Access, you could use
DoCmd.RunCommand acCmdPaste
How you paste the value from the clipboard into an external app is
something you can do manually with a Ctrl+V or Edit/Paste from it's menu.
Use Shell to open the external app or else use one of the API calls
found at
http://www.mvps.org/access.