Defining tables in calculations

L

Lenny

I am building a protected Word template invoice form (word 2003) and don't
want to insert an Excel spreadsheet for a number of reasons. How do I
reference a cell from a different table in the same document in the
calculation itself? (A4+Table2,B8)??????

Page 1 consists of table 1 and page 2, which is a continuation sheet,
contains table 2. Both tables use row calculations as: D1*E1=total to the
bottom of the page.

At the bottom of page 2, I want to add the cell results for a total for that
page. At the bottom of page 1, I wish to total all cell results in the last
column, carry or pull over the total from page 2, then add both total 1 and
total 2 for a 'grand total'.

I have been successful at compiling calculations in word tables (prior
versions) that add subtotals for a grand total for a number of years and have
never run into any problems. Totals calculate properly... Recently, I have
read in some of the threads from the mvp's that this is a problem with word
tables and you cannot add 'subtotals' that are results of a direct
calculation? Is there a better or different way of getting the correct
totals? (hidden column, direct references, etc?)

My thanks - Lenny
 
L

Lenny

Hi again macropod:
I downloaded your zipped file and there is a lot of great information in the
file. A question though, since it was not answered by anything in the
download.

Is there a problem with Words calculations involving sub-totals?
Example: 6 * 3 = 18 (subtotal) D1*E1 = F1
5 * 4 = 20 (subtotal) D2*E2 = F2
9 * 3 = 27 (subtotal) D3*E3 = F3
65 (total) =Sum(F1:F3)

The total is adding the calculated totals in cells F1 thru F3. As indicated
in my earlier post, I have seen posts that indicate that doing this poses
addition problems and inconsistencies. Have you found this to be the
case.....can you address this in a post and it could really mess up a lot of
peoples days, not to mention Word form templates..... my thanks - Lenny

macropod said:
Hi Lenny,

To do that you bookmark the whole table, then incorporate the bookmark name into your formula.

For an example how to do this and a wide range of other calculations in Word, check out my Word Field Maths 'tutorial', at:
http://www.wopr.com/cgi-bin/w3t/showthreaded.pl?Number=365442
or
http://www.gmayor.com/downloads.htm#Third_party
In particular, look at the item titled 'Reference Table Cells From Outside The Table'

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

Lenny said:
I am building a protected Word template invoice form (word 2003) and don't
want to insert an Excel spreadsheet for a number of reasons. How do I
reference a cell from a different table in the same document in the
calculation itself? (A4+Table2,B8)??????

Page 1 consists of table 1 and page 2, which is a continuation sheet,
contains table 2. Both tables use row calculations as: D1*E1=total to the
bottom of the page.

At the bottom of page 2, I want to add the cell results for a total for that
page. At the bottom of page 1, I wish to total all cell results in the last
column, carry or pull over the total from page 2, then add both total 1 and
total 2 for a 'grand total'.

I have been successful at compiling calculations in word tables (prior
versions) that add subtotals for a grand total for a number of years and have
never run into any problems. Totals calculate properly... Recently, I have
read in some of the threads from the mvp's that this is a problem with word
tables and you cannot add 'subtotals' that are results of a direct
calculation? Is there a better or different way of getting the correct
totals? (hidden column, direct references, etc?)

My thanks - Lenny
 
D

Doug Robbins - Word MVP

The problem occurs if formfields are being used as with a document that is
protected for forms.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

Lenny said:
Hi again macropod:
I downloaded your zipped file and there is a lot of great information in
the
file. A question though, since it was not answered by anything in the
download.

Is there a problem with Words calculations involving sub-totals?
Example: 6 * 3 = 18 (subtotal) D1*E1 = F1
5 * 4 = 20 (subtotal) D2*E2 = F2
9 * 3 = 27 (subtotal) D3*E3 = F3
65 (total) =Sum(F1:F3)

The total is adding the calculated totals in cells F1 thru F3. As
indicated
in my earlier post, I have seen posts that indicate that doing this poses
addition problems and inconsistencies. Have you found this to be the
case.....can you address this in a post and it could really mess up a lot
of
peoples days, not to mention Word form templates..... my thanks - Lenny

macropod said:
Hi Lenny,

To do that you bookmark the whole table, then incorporate the bookmark
name into your formula.

For an example how to do this and a wide range of other calculations in
Word, check out my Word Field Maths 'tutorial', at:
http://www.wopr.com/cgi-bin/w3t/showthreaded.pl?Number=365442
or
http://www.gmayor.com/downloads.htm#Third_party
In particular, look at the item titled 'Reference Table Cells From
Outside The Table'

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

Lenny said:
I am building a protected Word template invoice form (word 2003) and
don't
want to insert an Excel spreadsheet for a number of reasons. How do I
reference a cell from a different table in the same document in the
calculation itself? (A4+Table2,B8)??????

Page 1 consists of table 1 and page 2, which is a continuation sheet,
contains table 2. Both tables use row calculations as: D1*E1=total to
the
bottom of the page.

At the bottom of page 2, I want to add the cell results for a total for
that
page. At the bottom of page 1, I wish to total all cell results in the
last
column, carry or pull over the total from page 2, then add both total 1
and
total 2 for a 'grand total'.

I have been successful at compiling calculations in word tables (prior
versions) that add subtotals for a grand total for a number of years
and have
never run into any problems. Totals calculate properly... Recently, I
have
read in some of the threads from the mvp's that this is a problem with
word
tables and you cannot add 'subtotals' that are results of a direct
calculation? Is there a better or different way of getting the correct
totals? (hidden column, direct references, etc?)

My thanks - Lenny
 
M

macropod

Hi Lenny,

There is a problem when you use a formfield to calculate results based on other formfields. Since you can always use formula fields
instead, the really simple solution is to use formula fields instead of formfields to do calculate the results of any formfields. If
you're not using formfields (which you would for a document protected for forms), the problem doesn't arise.

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

Lenny said:
Hi again macropod:
I downloaded your zipped file and there is a lot of great information in the
file. A question though, since it was not answered by anything in the
download.

Is there a problem with Words calculations involving sub-totals?
Example: 6 * 3 = 18 (subtotal) D1*E1 = F1
5 * 4 = 20 (subtotal) D2*E2 = F2
9 * 3 = 27 (subtotal) D3*E3 = F3
65 (total) =Sum(F1:F3)

The total is adding the calculated totals in cells F1 thru F3. As indicated
in my earlier post, I have seen posts that indicate that doing this poses
addition problems and inconsistencies. Have you found this to be the
case.....can you address this in a post and it could really mess up a lot of
peoples days, not to mention Word form templates..... my thanks - Lenny

macropod said:
Hi Lenny,

To do that you bookmark the whole table, then incorporate the bookmark name into your formula.

For an example how to do this and a wide range of other calculations in Word, check out my Word Field Maths 'tutorial', at:
http://www.wopr.com/cgi-bin/w3t/showthreaded.pl?Number=365442
or
http://www.gmayor.com/downloads.htm#Third_party
In particular, look at the item titled 'Reference Table Cells From Outside The Table'

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

Lenny said:
I am building a protected Word template invoice form (word 2003) and don't
want to insert an Excel spreadsheet for a number of reasons. How do I
reference a cell from a different table in the same document in the
calculation itself? (A4+Table2,B8)??????

Page 1 consists of table 1 and page 2, which is a continuation sheet,
contains table 2. Both tables use row calculations as: D1*E1=total to the
bottom of the page.

At the bottom of page 2, I want to add the cell results for a total for that
page. At the bottom of page 1, I wish to total all cell results in the last
column, carry or pull over the total from page 2, then add both total 1 and
total 2 for a 'grand total'.

I have been successful at compiling calculations in word tables (prior
versions) that add subtotals for a grand total for a number of years and have
never run into any problems. Totals calculate properly... Recently, I have
read in some of the threads from the mvp's that this is a problem with word
tables and you cannot add 'subtotals' that are results of a direct
calculation? Is there a better or different way of getting the correct
totals? (hidden column, direct references, etc?)

My thanks - Lenny
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top