Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 05-05-2015, 12:07 PM
arkofcovenant arkofcovenant is offline Applying styles dynamically? Windows 7 64bit Applying styles dynamically? Office 2013
Novice
Applying styles dynamically?
 
Join Date: May 2015
Posts: 1
arkofcovenant is on a distinguished road
Default Applying styles dynamically?

So, I'm trying to make cards for a board game using mail merge. I'm not sure if there's a way to do this with mail merge or just a way to do it post merge?



Basically, I have two merge fields on separate lines in the center of my card. I would like to apply a style (specifically, shade the background of the paragraph, including the 1st line) based on the text in the second field. For instance, for every card with the text "AAA" in the second field, I want to shade both the second field and the first field with red in the background, and for every card with "BBB" I would like both fields to be blue, etc. I would need it to be edge to edge of the text area. I was trying to do it post merge with find and replace, but I can't get it to "find" and select the first field along with the second, and thus cant get it to apply the color to the first field. In addition, even when I get it to select the second field only, it only applies to color to the right of the text, and leaves the left side white.

Has anyone tried and succeeded with anything similar? Any solutions?
Reply With Quote
  #2  
Old 05-08-2015, 06:02 AM
Charles Kenyon Charles Kenyon is online now Applying styles dynamically? Windows 8 Applying styles dynamically? Office 2013
Moderator
 
Join Date: Mar 2012
Location: Sun Prairie, Wisconsin
Posts: 9,121
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

In your IF Field test for the presence of AAA. If present, have your truetext include your AAA field and the text you want. Make sure your IF field's truetext includes the paragraph mark. Format that truetext paragraph with your shading. Then have your falsetext be a separate paragraph with appropriate shading. Again, make sure the paragraph mark is within the falsetext quotation marks.
Reply With Quote
Reply

Tags
text style color dynamic

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Applying styles dynamically? Dynamically create documents MrRikkie Word VBA 1 10-12-2012 09:15 AM
draw charts dynamically pouya7525 PowerPoint 0 09-06-2012 10:45 AM
Applying styles dynamically? Dynamically creating new drop down boxes. dmncs Word VBA 1 05-06-2012 09:29 PM
Does Word do this when applying Styles to a paragraph a second time? Bobosmite Word 2 04-17-2012 02:13 PM
Publisher 2000 - Applying multiple styles Jerb Publisher 0 02-15-2009 10:06 AM

Other Forums: Access Forums

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