Transcription

[MS-OFFMACRO]:Office Macro-Enabled File FormatIntellectual Property Rights Notice for Open Specifications Documentation Technical Documentation. Microsoft publishes Open Specifications documentation forprotocols, file formats, languages, standards as well as overviews of the interaction among eachof these technologies. Copyrights. This documentation is covered by Microsoft copyrights. Regardless of any otherterms that are contained in the terms of use for the Microsoft website that hosts thisdocumentation, you may make copies of it in order to develop implementations of thetechnologies described in the Open Specifications and may distribute portions of it in yourimplementations using these technologies or your documentation as necessary to properlydocument the implementation. You may also distribute in your implementation, with or withoutmodification, any schema, IDL’s, or code samples that are included in the documentation. Thispermission also applies to any documents that are referenced in the Open Specifications. No Trade Secrets. Microsoft does not claim any trade secret rights in this documentation. Patents. Microsoft has patents that may cover your implementations of the technologiesdescribed in the Open Specifications. Neither this notice nor Microsoft's delivery of thedocumentation grants any licenses under those or any other Microsoft patents. However, a givenOpen Specification may be covered by Microsoft Open Specification Promise or the CommunityPromise. If you would prefer a written license, or if the technologies described in the OpenSpecifications are not covered by the Open Specifications Promise or Community Promise, asapplicable, patent licenses are available by contacting [email protected] Trademarks. The names of companies and products contained in this documentation may becovered by trademarks or similar intellectual property rights. This notice does not grant anylicenses under those rights. Fictitious Names. The example companies, organizations, products, domain names, e-mailaddresses, logos, people, places, and events depicted in this documentation are fictitious. Noassociation with any real company, organization, product, domain name, email address, logo,person, place, or event is intended or should be inferred.Reservation of Rights. All other rights are reserved, and this notice does not grant any rightsother than specifically described above, whether by implication, estoppel, or otherwise.Tools. The Open Specifications do not require the use of Microsoft programming tools orprogramming environments in order for you to develop an implementation. If you have access toMicrosoft programming tools and environments you are free to take advantage of them. CertainOpen Specifications are intended for use in conjunction with publicly available standardspecifications and network programming art, and assumes that the reader either is familiar with theaforementioned material or has immediate access to it.1 / 46[MS-OFFMACRO] — v20130206Office Macro-Enabled File FormatCopyright 2013 Microsoft Corporation.Release: February 11, 2013

Revision 13/20090.1MajorInitial Availability08/28/20090.2EditorialRevised and edited the technical content11/06/20090.3EditorialRevised and edited the technical content02/19/20101.0EditorialRevised and edited the technical content03/31/20101.01EditorialRevised and edited the technical content04/30/20101.02EditorialRevised and edited the technical content06/07/20101.03EditorialRevised and edited the technical content06/29/20101.04EditorialChanged language and formatting in the technicalcontent.07/23/20101.04No changeNo changes to the meaning, language, or formatting ofthe technical content.09/27/20101.04No changeNo changes to the meaning, language, or formatting ofthe technical content.11/15/20101.04No changeNo changes to the meaning, language, or formatting ofthe technical content.12/17/20101.04No changeNo changes to the meaning, language, or formatting ofthe technical content.03/18/20111.04No changeNo changes to the meaning, language, or formatting ofthe technical content.06/10/20111.04No changeNo changes to the meaning, language, or formatting ofthe technical content.01/20/20121.5MinorClarified the meaning of the technical content.04/11/20121.5No changeNo changes to the meaning, language, or formatting ofthe technical content.07/16/20121.5No changeNo changes to the meaning, language, or formatting ofthe technical content.10/08/20121.5No changeNo changes to the meaning, language, or formatting ofthe technical content.02/11/20131.5No changeNo changes to the meaning, language, or formatting ofthe technical content.2 / 46[MS-OFFMACRO] — v20130206Office Macro-Enabled File FormatCopyright 2013 Microsoft Corporation.Release: February 11, 2013

Table of Contents1Introduction . 51.1 Glossary . 51.2 References . 61.2.1 Normative References . 61.2.2 Informative References . 61.3 Structure Overview (Synopsis) . 61.3.1 Organization of This Document . 61.4 Relationship to Protocols and Other Structures . 71.5 Applicability Statement . 71.6 Versioning and Localization . 71.7 Vendor-Extensible Fields . 72Structures . 82.1 Macro-Enabled WordprocessingML Structures . 82.1.1 Part Enumeration . 82.1.1.1 Main Document . 82.1.1.2 VBA Project. 82.1.1.3 VBA Supplemental Data. 92.1.2 Global Elements . 92.1.2.1 vbaSuppData . 92.1.3 Global Attributes . 92.1.4 Complex Types . 92.1.4.1 CT Mcd . 92.1.4.2 CT Mcds. 102.1.4.3 CT DocEvents . 102.1.4.4 CT VbaSuppData. 112.1.5 Simple Types . 122.2 Macro-Enabled SpreadsheetML Structures. 122.2.1 Part Enumeration . 122.2.1.1 Workbook . 122.2.1.2 VBA Project. 122.2.1.3 Macro Sheet. 132.2.1.4 International Macro Sheet . 142.2.2 Global Elements . 142.2.2.1 macrosheet . 142.2.3 Global Attributes . 142.2.4 Complex Types . 142.2.4.1 CT Worksheet . 142.2.5 Simple Types . 172.2.6 Formulas . 172.3 Macro-Enabled PresentationML Structures . 352.3.1 Part Enumeration . 352.3.1.1 Presentation . 352.3.1.2 VBA Project. 352.3.2 Global Elements . 352.3.3 Global Attributes . 362.3.4 Complex Types . 362.3.4.1 CT SlideMasterIdListEntry . 362.3.5 Simple Types . 363 / 46[MS-OFFMACRO] — v20130206Office Macro-Enabled File FormatCopyright 2013 Microsoft Corporation.Release: February 11, 2013

3Structure Examples . 373.1 VBA Supplemental Data Part of a Word-Processing Document . 373.2 Macro Sheet Part of a Workbook . 374Security Considerations. 395Appendix A: Full XML Schemas . 405.1 ml . 405.2 n . 416Appendix B: Product Behavior . 437Change Tracking. 448Index . 454 / 46[MS-OFFMACRO] — v20130206Office Macro-Enabled File FormatCopyright 2013 Microsoft Corporation.Release: February 11, 2013

1IntroductionThis document specifies the Office Macro-Enabled File Format for WordprocessingML,SpreadsheetML, and PresentationML file formats that are either not present in or modified from nonmacro-enabled WordprocessingML, SpreadsheetML, and PresentationML file formats described in[ECMA-376]. The macro-enabled file formats consist of the non-macro-enabled file formatsdescribed in [ECMA-376] and the XML structures and the XML and non-XML parts specified in thisdocument.Sections 1.7 and 2 of this specification are normative and can contain the terms MAY, SHOULD,MUST, MUST NOT, and SHOULD NOT as defined in RFC 2119. All other sections and examples in thisspecification are informative.1.1GlossaryThe following terms are defined in [MS-GLOS]:XMLThe following terms are defined in [MS-OFCGLOS]:AutoFilterconditional formattingdata consolidationdocumentembedded objectHypertext Markup Language (HTML)localemacromacro sheetpage breakphonetic informationpresentationprotectionrangesheetsheet viewsort conditiontableVisual Basic for Applications (VBA)VMLworkbookworksheetThe following terms are specific to this document:page margin: The white space at the top, bottom, and sides of a document when a document isprinted.MAY, SHOULD, MUST, SHOULD NOT, MUST NOT: These terms (in all caps) are used asdescribed in [RFC2119]. All statements of optional behavior use either MAY, SHOULD, orSHOULD NOT.5 / 46[MS-OFFMACRO] — v20130206Office Macro-Enabled File FormatCopyright 2013 Microsoft Corporation.Release: February 11, 2013

1.2ReferencesReferences to Microsoft Open Specifications documentation do not include a publishing year becauselinks are to the latest version of the technical documents, which are updated frequently. Referencesto other documents include a publishing year when one is available.1.2.1Normative ReferencesWe conduct frequent surveys of the normative references to assure their continued availability. Ifyou have any issue with finding a normative reference, please contact [email protected] Wewill assist you in finding the relevant information. Please check the archive 6494-0