Normally, you add quote marks to your text as you type. There may be times, however, when you want to add the quote marks at a later time. For instance, while editing your document you may select some text and then want quote marks added around the selected text. You can accomplish this task with the following macro:
Sub AddQuotes() Dim sBegQ As String Dim sEndQ As String If Options.AutoFormatAsYouTypeReplaceQuotes Then sBegQ = Chr(147) sEndQ = Chr(148) Else sBegQ = Chr(34) sEndQ = Chr(34) End If Selection.InsertBefore sBegQ Selection.InsertAfter sEndQ End Sub
The macro determines the proper type of quote marks to use, based on whether you have Word's SmartQuotes turned on or not. The proper quotes are then placed before and after the selection.
Note:
WordTips is your source for cost-effective Microsoft Word training. (Microsoft Word is the most popular word processing software in the world.) This tip (13326) applies to Microsoft Word 2007, 2010, 2013, 2016, 2019, and Word in Office 365. You can find a version of this tip for the older menu interface of Word here: Adding Quotes.
Learning Made Easy! Quickly teach yourself how to format, publish, and share your content using Word 2013. With Step by Step, you set the pace, building and practicing the skills you need, just when you need them! Check out Microsoft Word 2013 Step by Step today!
Should you put two spaces after a sentence or just one? Ask different people and you will get different answers. To Word ...
Discover MoreInserting a date and time in your document is a snap using the tools provided in Word. Just pick the command, then ...
Discover MoreWhen creating tracking documents in Word, you may need to come up with a series of dates in the document. You can type ...
Discover MoreFREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."
2015-03-11 07:34:16
Jerry
WORD 2013
When I select a line, either by click and drag or triple click, it also selects the paragraph mark at the end of the line. This forces the closing quote to the beginning of the next line.
I can select up to the last character before the period, but that puts the closing quote before the period.
Does anyone know a workaround for the selection problem?
Got a version of Word that uses the ribbon interface (Word 2007 or later)? This site is for you! If you use an earlier version of Word, visit our WordTips site focusing on the menu interface.
FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."
Copyright © 2021 Sharon Parq Associates, Inc.
Comments