View Single Post
 
Old 01-24-2022, 04:43 PM
exoson exoson is offline Windows 7 64bit Office 2010 32bit
Novice
 
Join Date: Jan 2014
Posts: 6
exoson is on a distinguished road
Default Determine Style of paragraph at current location

I need to use the paragraph Style at the current location to select what action I need to take.
Another VBA macro will be called based on the style.

E.g., If the Style is "Introduction" then

delete the current paragraph,


'insert some text from the clipboard

Selection.PasteAndFormat (wdFormatPlainText)


' prepare the next paragraph
Selection.Style = ActiveDocument.Styles("Body")


How do I determine the current style?
Reply With Quote