CalculateOnExit Class
Recalculate Fields When Current Field Is Modified.When the object is serialized out as xml, its qualified name is w:calcOnExit.
Inheritance Hierarchy
System.Object
DocumentFormat.OpenXml.OpenXmlElement
DocumentFormat.OpenXml.OpenXmlLeafElement
DocumentFormat.OpenXml.Wordprocessing.OnOffType
DocumentFormat.OpenXml.Wordprocessing.CalculateOnExit
Namespace: DocumentFormat.OpenXml.Wordprocessing
Assembly: DocumentFormat.OpenXml (in DocumentFormat.OpenXml.dll)
Syntax
'Declaration
Public Class CalculateOnExit _
Inherits OnOffType
'Usage
Dim instance As CalculateOnExit
public class CalculateOnExit : OnOffType
Remarks
[ISO/IEC 29500-1 1st Edition]
17.16.1 calcOnExit (Recalculate Fields When Current Field Is Modified)
This element specifies that the current contents of all fields within the current WordprocessingML document shall be recalculated from their field codes when the contents of the parent form field are modified. [Note: It is at the discretion of an application to determine the scope of a single modification, for example, when the user moves the insertion point in a user interface, or after each keystroke, etc. end note]
If this element is omitted, then modification of the contents of the current field shall not result in all fields in the current document being recalculated.
[Example: Consider the following WordprocessingML fragment for the contents of two fields in a document:
<w:bookmarkStart w:name="Text1" … /> <w:fldSimple w:instr="FORMFIELDTEXT"> <w:ffData> <w:calcOnExit/> … </w:ffData> <w:r> <w:t>1</w:t> </w:r> </w:fldSimple> <w:bookmarkEnd … /> <w:fldSimple w:instr="=Text1+10"> <w:r> <w:t>11</w:t> </w:r> </w:fldSimple>
The first field above (the text form field) has a current value of 1, but also has the calcOnExit element present (therefore inheriting its default attribute value of true). This means that if the value of this form field is changed to 10, that all fields in the document must automatically be updated, resulting in the second field's value being automatically changed to 20. end example]
Parent Elements |
---|
ffData (§17.16.17) |
This element’s content model is defined by the common boolean property definition in §17.17.4.
© ISO/IEC29500: 2008.
Thread Safety
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.