Export (0) Print
Expand All
Expand Minimize
This topic has not yet been rated - Rate this topic

Range.Calculate Method (Word)

Published: July 16, 2012

Calculates a mathematical expression within a range or selection. Returns the result as a Single.

expression .Calculate

expression Required. A variable that represents a Range object.

This example inserts a mathematical expression at the beginning of the active document, calculates the expression, and then appends the results to the range. The result is "1 + 1 = 2".

Set myRange = ActiveDocument.Range(0, 0) 
myRange.InsertBefore "1 + 1 " 
myRange.InsertAfter "= " & myRange.Calculate
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

© 2014 Microsoft. All rights reserved.