VBA to Copy Excel cells (one at a time) text to Windows Clipboard so that the text can be Pasted into another application using Windows+V

WFCompany

New Member
Joined
Nov 12, 2024
Messages
2
Office Version
  1. 365
Platform
  1. Windows
I frequently need to copy the text from Excel spreadsheet's cells into other applications that do not use VBA.
The Customer's Name, Street Address, City, State, Phone Number, Email Address, etc. are all in different cells in the same worksheet.
The text then needs to be Pasted into another application using the Windows+V paste function.

I want to be able to create VBA code that will achieve the copying of each field into Windows Clipboard from one Button in Excel.
I have tried numerous methods, but the Windows Clipboard only contains blank values if more than one cell is selected and copied.

Please help!
Thanks
 

Excel Facts

Is there a shortcut key for strikethrough?
Ctrl+S is used for Save. Ctrl+5 is used for Strikethrough. Why Ctrl+5? When you use hashmarks to count |||| is 4, strike through to mean 5.
Welcome to the forum one way to explore is to look at using SendKeys method. You might end up exploring a time delay to switch to another app as well as shell command.

There are lots of sites that could help. Perhaps this site will give you a start point.

 
Upvote 0
Welcome to the forum one way to explore is to look at using SendKeys method. You might end up exploring a time delay to switch to another app as well as shell command.

There are lots of sites that could help. Perhaps this site will give you a start point.

Thanks for the suggestion.
My first objective was to code the gathering of info from Excel - each field being a line in Windows+V.
The pasting into the other application could still be manual.
Your suggestion may allow me to do more than I had hoped. How are the Key values copied from Excel? How would this work for an application that is not part of Windows e.g. legacy software.
 
Upvote 0

Forum statistics

Threads
1,223,632
Messages
6,173,467
Members
452,516
Latest member
archcalx

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top