Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #2  
Old 04-12-2025, 01:35 AM
macropod's Avatar
macropod macropod is offline A simple macro to copy a returned string to clipboard Windows 10 A simple macro to copy a returned string to clipboard Office 2016
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,369
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

For example:
Code:
Sub Demo()
' Note: A VBA reference to the MS Forms Object Library is required. See Tools|References in the VBE.
Dim MyData As DataObject: Set MyData = New DataObject
MyData.SetText "My Text String": MyData.PutInClipboard
End Sub
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
A simple macro to copy a returned string to clipboard Paste from Clipboard, Find and Replace All, Then Copy Results Back to The Clipboard robnun Word VBA 7 01-03-2025 12:52 PM
A simple macro to copy a returned string to clipboard Copy Specific Text String To Clipboard At End Of Macro et_33 Excel Programming 8 10-11-2022 06:24 AM
WORD MACRO COPY/PAST from clipboard rachidlea Word VBA 0 11-16-2021 09:38 AM
A simple macro to copy a returned string to clipboard Simple macro to create a copy eduzs Word VBA 3 05-17-2017 05:34 PM
A simple macro to copy a returned string to clipboard copy without using clipboard? g48dd Excel 3 07-16-2011 10:28 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 06:38 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft