When a custom Document Information Panel is associated with an Office document and/or template, the information needed to locate the Panel is contained in a custom XML data part stored with the document.I won’t go into the details of the way an Office Open XML document is structured here (needless to say there are many great resources for this on the web), but the format is basically a ZIP file with a collection of XML files that describe the contents of the word processing, spreadsheet, or presentation. Those XML files are linked to each other via logical “relationships” that define the necessary semantics (e.g. that one file contains the content for the header).
In the terms familiar to the Office Open specification, a custom XML data part is stored at the following location in an Office Open XML document:
Basically, the data is stored in an XML file which is logically related to the main part for that file type, and whose logical relationship is of type “customXml”.Now then, the other half of the definition of a custom Document Information Panel is the content of that custom XML data part. Here’s an example of the data stored in the custom XML data part for a custom Document Information Panel:
<customPropertyEditors xmlns="http://schemas.microsoft.com/office/2006"> <showOnOpen> true </showOnOpen> <defaultPropertyEditorNamespace> http://schemas.microsoft.com/office/infopath/2003/myXSD/2005-10-21T21:12:27 </defaultPropertyEditorNamespace> <customPropertyEditor> <XMLNamespace> http://schemas.microsoft.com/office/infopath/2003/myXSD </XMLNamespace> <XSNLocation> \\contoso-server\forms\assetForm.xsn </XSNLocation> </customPropertyEditor></customPropertyEditors>
This part defines the settings for the Document Information Panel by using the following four elements:
The contents of this element are one of two choices:• Standard properties – this setting shows the default Office 2007 property template• <custom XML namespace> - if the template to be shown should be a custom Document Information Panel stored with the document, its root XML namespace is stored in this element, so Office can locate and display this information automatically when the Document Information Panel is shown
With that information defined, Office automatically locates a custom Document Information Panel and displays it as requested. Note that none of these steps involve using Office to set up the Document Information Panel – this process can be automated without Office (for example, to add a Document Information Panel to a template as part of a server-based process).
Alnur AliProgram Manager
Alnur,
Do you whether you can show a modal dialog from a DIP or is this disabled? I am running a fully trusted form and the XDocument.UI.ShowModalDialog method returns an error from script.
Pete.
When a custom Document Information Panel is associated with an Office document and/or template, the information needed to locate the Panel is contained in a custom XML data part stored with the document. I won’t go into the details of the way an Offic