Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 08-30-2018, 02:23 PM
macropod's Avatar
macropod macropod is offline Removing trailing spaces from footnotes Windows 7 64bit Removing trailing spaces from footnotes Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,513
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

So how would the macro be supposed to tell when a hyperlink shouldn't have the trailing space removed, or when a paragraph in a footnote shouldn't have trailing spaces removed? It seems to me you want it to do what you asked, except when you don't... And you did say you were:
Quote:
looking for a way to remove any trailing spaces from all footnotes.
and:
Quote:
Footnotes can have multiple hyperlinks and the last character may be within one of them and be a space or other character I want rid of
It also correctly handles the situation where:
Quote:
their spaces may be separating words between Hyperlinks and non hyperlink text

__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #2  
Old 08-30-2018, 02:58 PM
risomd risomd is offline Removing trailing spaces from footnotes Windows 7 64bit Removing trailing spaces from footnotes Office 2016
Novice
Removing trailing spaces from footnotes
 
Join Date: Aug 2018
Posts: 6
risomd is on a distinguished road
Default

Quote:
Originally Posted by macropod View Post
So how would the macro be supposed to tell when a hyperlink shouldn't have the trailing space removed, or when a paragraph in a footnote shouldn't have trailing spaces removed? It seems to me you want it to do what you asked, except when you don't... And you did say you were:

and:
Exactly this. Iterating through paragraphs of the wdFootnotesStory will not indicate to which footnote they belong.


Iterating the footnotes and their paragraphs lets you determine which is the last paragraph of a footnote (see my initial post).

I will guess that the last hyperlink of the last paragraph of a footnote is the one to potentially trim *if* there isn't any non-hyperlink-text after it (once the last paragraph's characters have been trimmed).
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
Removing trailing spaces from footnotes Removing spaces in activedocument after empty bookmarks faustino909 Word VBA 2 08-03-2018 01:34 PM
Removing trailing spaces from footnotes How to remove trailing & leading spaces in a cell? LearnerExcel Excel Programming 8 02-04-2018 08:22 PM
Removing trailing spaces from footnotes removing spaces in cell Tonykiwi Excel 4 11-06-2016 09:30 PM
Removing trailing spaces from footnotes Mail Merge - Trailing Spaces osucjb Mail Merge 5 10-28-2016 12:03 AM
Word-Help with removing unwanted spaces in text greshoff Word 9 12-30-2011 03:24 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 11:35 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