A Microsoft Word forum. Microsoft Office Word Forum - WordBanter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Microsoft Office Word Forum - WordBanter forum » Microsoft Word Newsgroups » Tables
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Colour Coding Table Cells in Multiple Tables in One Document



 
 
Thread Tools Display Modes
  #1  
Old January 26th 15, 04:35 PM
EdG2015 EdG2015 is offline
Junior Member
 
First recorded activity by WordBanter: Jan 2015
Posts: 2
Default Colour Coding Table Cells in Multiple Tables in One Document

Hi all,

I've searched all over and can't find something that's giving the results that I want, so any assistance would be greatly appreciated!

I am creating a document in Word 2010 which has around 20 tables in it each of which is of varying size. I need to apply something akin to conditional formatting in Excel which will vary for each table. For example, I want one table to format cells (using excel-type references) C3, F3, I3 and L3 with red text if 80%, amber if 80-99.99% and green if 100%. Another table I want to format anything in row 4 which is a negative as red 0-3 as amber and 4 or more in green.

I know that I could embed excel sheets within the document but this doesn't fit with what I want to achieve, so am looking for a word solution either through VBA or otherwise. If using VBA, would appreciate if someone could point me in the direction of identifying individual tables in the document so the right formatting is applied to the right table. Apologies if this is a pretty dim question - Word is not my natural environment!

Thanks.
Ads
  #2  
Old January 26th 15, 08:03 PM
EdG2015 EdG2015 is offline
Junior Member
 
First recorded activity by WordBanter: Jan 2015
Posts: 2
Cool

Hi,

I've managed to resolve by using a nested if function with \*Charformat switch. If anyone else struggles like me I've put the format below. Note use Ctrl+F9 to get the curly brackets ({}]:

{ IF { =(a1/a2)*100 } = 100 { =(a1/a2)*100 \# “#%” \*Charformat } { IF { =(a1/a2)*100 } 80 { =(a1/a2)*100 \# “#%” \Charformat } { =(a1/a2)*100 \# “#%” \*Charformat } } }

Where the underlined section has dark green text and light green background through the font and paragraph formatting, the bold section dark red text and light red background and the bold section dark orange text and yellow background. This replicates the red/amber/green conditional formatting of excel where green is =100%, amber is 80-99.9999% and red is 80%, and the sum is cell A1/A2 (could be replaced with R1C1/R2C1). This can be modified accordingly to allow for multiple variables (up to 20 I believe) and with differing formats and inputs.

Hope this helps someone else who has struggled like I have!
  #3  
Old November 24th 15, 04:21 AM
nananaja003 nananaja003 is offline
Junior Member
 
First recorded activity by WordBanter: Oct 2015
Posts: 3
Default

I've managed to resolve by using a nested if function with
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How do you create a formula from cells in multiple tables? Marilyn75287 Tables 4 May 30th 09 02:31 AM
Adding Numbers of Multiple Cells in a Table Bettina Microsoft Word Help 7 July 5th 07 06:46 PM
Creating a TOC from multiple cells of a table. Scott Tables 2 October 26th 06 08:43 AM
color coding cells motocrossed Tables 1 April 28th 06 10:23 AM
I want text from the cells in one table repeated in other tables Reg Tables 2 February 14th 06 01:53 PM


All times are GMT +1. The time now is 01:28 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright ©2004-2017 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.