Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 08-20-2018, 06:46 AM
lacja lacja is offline Display hidden text based on values in other part of text Windows 7 64bit Display hidden text based on values in other part of text Office 2016
Novice
Display hidden text based on values in other part of text
 
Join Date: Aug 2018
Posts: 3
lacja is on a distinguished road
Default Display hidden text based on values in other part of text

Hi,



we'd like to do something like that in a word document :

"Dear Mrs xyz, referring to article 28.1, 30.3 and 30.4, we will not bla bla bla bla"

And on another page, we'll have all articles (28, 28.1, 29, 30.1, 30.2, 30.3, 30.4, ...) but only show articles that match these from the first page (28.1, 30.3, 30.4)

Is it possible?
Will we need so VBA to accomplish that?
Reply With Quote
  #2  
Old 08-20-2018, 11:09 AM
Charles Kenyon Charles Kenyon is offline Display hidden text based on values in other part of text Windows 10 Display hidden text based on values in other part of text Office 2013
Moderator
 
Join Date: Mar 2012
Location: Sun Prairie, Wisconsin
Posts: 9,083
Charles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant future
Default

This can be done with Fields or vba. Where possible, I prefer fields because not all Word environments can use macros.

On the first page you would want a bookmarked drop-down content control that has all the options you might use. Then you would want your conditional text to be in IF Fields. This will be complex. I would recommend starting small.

Your IF Fields will need to test for any of the choices that could call for display. Note that IF fields will not update automatically. You might get around this by using Mapped Content Controls. I'm not sure.

You could also use legacy formfields but I recommend avoiding them unless needed.


See my Gender Toolbar Add-In for examples of IF fields.
Reply With Quote
  #3  
Old 08-20-2018, 11:17 AM
Charles Kenyon Charles Kenyon is offline Display hidden text based on values in other part of text Windows 10 Display hidden text based on values in other part of text Office 2013
Moderator
 
Join Date: Mar 2012
Location: Sun Prairie, Wisconsin
Posts: 9,083
Charles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant future
Default

There are limits to the size of the "TrueText" in an If Field. If you run into those, you could use AutoText and AutoText fields to hold your text.
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Display hidden text based on values in other part of text Find text, format part of text in italic d4okeefe Word VBA 18 06-30-2022 11:35 PM
Display multiple values as new values based on selection from template. MvdB Excel 2 09-29-2015 08:51 PM
Help: how to replace hidden text with unhidden text when typing over jdcornelius Word 6 03-28-2014 01:19 PM
Display paragraph of text based on value selected in combo WordWaza Word 0 08-09-2013 06:30 AM
Display hidden text based on values in other part of text Hidden style applied over already-hidden text. christie Word 1 08-17-2011 09:10 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 10:52 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft