Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 04-01-2014, 03:45 PM
macropod's Avatar
macropod macropod is offline go to next heading, if there is one Windows 7 32bit go to next heading, if there is one Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,521
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

Hi Gerry,



I was intentionally inserting the "</case>" into the end of the heading paragraph, rather than into the start of the one after it; otherwise, I'd have just used .InsertAfter without reference to .Characters.Last.

I also deliberately implement a loop in anticipation that the OP might want to add some other content in or around either or both of the "<case>" and "</case>" strings (e.g. the heading level and/or the index # of that heading). It would actually be more efficient to use ReplaceAll for what has been specified.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
go to next heading, if there is one How to add space between heading number and heading text Dr Wu Word 4 07-15-2018 03:52 AM
go to next heading, if there is one How to Restore Heading 1, Heading 2, etc. within a Word Document cheech1981 Word 9 01-11-2017 02:14 AM
go to next heading, if there is one Heading title before heading number johnor999 Word 4 12-06-2013 12:39 AM
Control the size of space between heading number and heading text Dr Wu Word 1 07-17-2013 12:24 PM
go to next heading, if there is one Styles: Heading 4 stuck at same heading number Hallet Word 1 05-31-2012 02:37 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 03:50 PM.


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