Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 12-15-2022, 03:36 PM
carnau carnau is offline Copy to clipboard button. Windows 10 Copy to clipboard button. Office 2010
Novice
Copy to clipboard button.
 
Join Date: Dec 2022
Posts: 2
carnau is on a distinguished road
Default Copy to clipboard button.


Hello Everyone,

If I want to type out a sentence and then put a button beside it that lets people copy the sentence by just pressing the button is that possible?

Thank you in advance,
Chris
Reply With Quote
  #2  
Old 12-15-2022, 04:45 PM
Charles Kenyon Charles Kenyon is offline Copy to clipboard button. Windows 11 Copy to clipboard button. Office 2021
Moderator
 
Join Date: Mar 2012
Location: Sun Prairie, Wisconsin
Posts: 9,125
Charles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant future
Default

What is the purpose of this? The end game?
Reply With Quote
  #3  
Old 12-15-2022, 05:51 PM
macropod's Avatar
macropod macropod is offline Copy to clipboard button. Windows 10 Copy to clipboard button. Office 2016
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,962
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

Why would they need a button, when triple-clicking would select the whole paragraph?

You also need to be aware that VBA has no idea what a grammatical sentence is. For example, consider the following:
Mr. Smith spent $1,234.56 at Dr. John's Grocery Store, to buy: 10.25kg of potatoes; 10kg of avocados; and 15.1kg of Mrs. Green's Mt. Pleasant macadamia nuts.
For you and me, that would count as one sentence; for VBA it counts as 5 sentences.

A button-based solution would require VBA.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #4  
Old 12-15-2022, 06:29 PM
carnau carnau is offline Copy to clipboard button. Windows 10 Copy to clipboard button. Office 2010
Novice
Copy to clipboard button.
 
Join Date: Dec 2022
Posts: 2
carnau is on a distinguished road
Default

So right now You have to copy the sentence, right click on it, copy to clipboard and then you can paste it.

Or you can copy it, Ctrl+V, then paste it.

I was just trying to make it so they didn't have to copy it, and then paste it. I am an Automotive instructor and there are certain sentences like "Working as designed at time of testing."

Right now they copy the sentence from word and paste it to the programing they use to fill out repair orders. I was just trying to make it easier for them. Where I could put a button or clipboard icon or something they could click instead of highlighting the whole sentence and then copying it.

I hope the above makes sense. I can rebuild an engine with every part disassembled in no order and scattered, but I have a hard time with things like this.
Reply With Quote
  #5  
Old 12-15-2022, 07:42 PM
Charles Kenyon Charles Kenyon is offline Copy to clipboard button. Windows 11 Copy to clipboard button. Office 2021
Moderator
 
Join Date: Mar 2012
Location: Sun Prairie, Wisconsin
Posts: 9,125
Charles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant future
Default

Look into AutoText.
AutoText
Reply With Quote
  #6  
Old 12-20-2022, 10:47 AM
kilroyscarnival kilroyscarnival is offline Copy to clipboard button. Windows 10 Copy to clipboard button. Office 2021
Expert
 
Join Date: May 2019
Posts: 344
kilroyscarnival is just really nicekilroyscarnival is just really nicekilroyscarnival is just really nicekilroyscarnival is just really nice
Default

Carnau, any luck with this? I second Mr. Kenyon's recommendation of AutoText. It requires a little setup but if you use phrases, sentences, paragraphs, or lists over and over again, it's really easy to use. I also keep a button on my Quick Access Toolbar (see image) which can get me into the most common ones.

Another little trick is, you can use Word's AutoCorrect feature to help you. Rather than my typing out Report of Geotechnical Engineering Exploration every time, I have a custom AutoCorrect to when I type GEX it replaces with those words written out. Or if it's sometimes something i want in the abbreviated form (AASHTO) and sometimes written out "American Association of State Highway and Transportation Officials (AASHTO)" I make the trigger something unique, like "&AASHTO" or "AASHTOx". That way when I just type it normally it doesn't expand. You'd set these up under File/Options/Proofing/Autocorrect Options. The thing is, each user would have to set this up on his or her Word profile. There's a way to share the AutoText as embedded with a particular template, which is helpful if more than one person is going to be using it.
Attached Images
File Type: jpg autotext.jpg (88.2 KB, 16 views)
Reply With Quote
  #7  
Old 12-20-2022, 10:40 PM
gmayor's Avatar
gmayor gmayor is offline Copy to clipboard button. Windows 10 Copy to clipboard button. Office 2019
Expert
 
Join Date: Aug 2014
Posts: 4,101
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

As it appears that the phrases to be copied are to be pasted into another application then another approach would be to use a content control list box that contains the phrases coupled with a simple macro that copies the selected item from the list box to the clipboard. See the example attached. You can edit the list from the content controls properties, or more simply by using Insert Content Control Add-In
Attached Files
File Type: docm Choose the phrase to copy.docm (33.7 KB, 13 views)
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote
  #8  
Old 12-22-2022, 06:55 AM
kilroyscarnival kilroyscarnival is offline Copy to clipboard button. Windows 10 Copy to clipboard button. Office 2021
Expert
 
Join Date: May 2019
Posts: 344
kilroyscarnival is just really nicekilroyscarnival is just really nicekilroyscarnival is just really nicekilroyscarnival is just really nice
Default

Quote:
Originally Posted by gmayor View Post
As it appears that the phrases to be copied are to be pasted into another application then another approach would be to use a content control list box that contains the phrases coupled with a simple macro that copies the selected item from the list box to the clipboard. See the example attached. You can edit the list from the content controls properties, or more simply by using Insert Content Control Add-In
Graham, you just gave me something to look into, hopefully next week when we should be slow at the office. I haven't used Content Controls very extensively, so it'll give me something to explore further. So whether or not it addresses the OP's needs, thanks!

Best regards,

Ann
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
WORD MACRO COPY/PAST from clipboard rachidlea Word VBA 0 11-16-2021 09:38 AM
copy to clipboard in exel yacov Excel 7 07-20-2021 11:26 PM
Copy to clipboard button. Replicate the copy/paste function, without involving the clipboard alex100 Word VBA 8 11-09-2020 08:19 AM
Copy to clipboard button. Mark text in a text box and copy to clipboard (with button) ArthurM PowerPoint 4 02-19-2012 11:33 AM
Copy to clipboard button. 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:26 PM.


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