Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #14  
Old 04-16-2020, 06:43 AM
macropod's Avatar
macropod macropod is offline Abbreviations Validation - Word Windows 7 64bit Abbreviations Validation - Word Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,523
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

Quote:
Originally Posted by mrsandes View Post
if I were to find also abbreviations that are not enclosed by parenthesis, what else would I have to delete on the code?

I just removed the "\(" and "\)" on the search mechanism, but it gives me an error "Subscript out of range" and highlights the line:

Code:
StrAcronyms = StrAcronyms & Split(StrTmp, "|")(1) & vbTab & Split(StrTmp, "|")(0) & vbCr
Simply omitting the "\(" and "\)" is sufficient for the Find, but the highlighted line depends on the presence of '|' characters, which are inserted by the preceding line:
Code:
StrTmp = Replace(Replace(Replace(.Text, " (", "("), "(", "|"), ")", "")
In any event, that change is liable to result is far more false matches.
Quote:
Originally Posted by mrsandes View Post
Another thing that I noticed is that the AcronymManager macro will not replace the text in the document for the acronym if the text is not capitalized in each word... What I mean is, if I have the acronym Part List (PL) found and listed in the acronyms table, it will update in the document every instance that "Part List" is written, replacing by "PL", but it will not replace the instances where "part list" is written. Would it be possible to change that setting?
That's because it was assumed that strings such as 'parts list' might be intentional non-uses of the defined term. You can alter the behaviour by changing:
.MatchCase = True
to:
.MatchCase = False
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
Abbreviations Validation - Word Creating a list of Acronyms / Abbreviations daithy Word 4 03-12-2020 01:52 PM
Data Validation in Microsoft Word Template BradleyCase Word VBA 1 07-16-2019 12:37 PM
Adding Professional Credential Abbreviations to Name dyny723 Outlook 0 03-16-2018 07:14 AM
Abbreviations Validation - Word Automate Job application word doc to Excel (with data validation) dylansmith Office 1 02-11-2018 12:58 PM
validation email address in word text filed sameerahmad_P Word VBA 1 03-07-2014 02:59 PM

Other Forums: Access Forums

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