Class OfficeProperties
Provides access to the properties bag of the package
Inherited Members
Namespace: OfficeOpenXml
Assembly: EPPlus.dll
Syntax
public sealed class OfficeProperties : XmlHelper
  Properties
Application
Gets/Set the Application property of the document (extended property)
Declaration
public string Application { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.String | 
AppVersion
Gets/Set the AppVersion property of the document (extended property)
Declaration
public string AppVersion { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.String | 
Author
Gets/sets the author property of the document (core property)
Declaration
public string Author { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.String | 
Category
Gets/sets the category property of the document (core property)
Declaration
public string Category { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.String | 
Comments
Gets/sets the comments property of the document (core property)
Declaration
public string Comments { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.String | 
Company
Gets/sets the Company property of the document (extended property)
Declaration
public string Company { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.String | 
CorePropertiesXml
Provides access to the XML document that holds all the code document properties.
Declaration
public XmlDocument CorePropertiesXml { get; }
  Property Value
| Type | Description | 
|---|---|
| System.Xml.XmlDocument | 
Created
Gets/sets the created property of the document (core property)
Declaration
public DateTime Created { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.DateTime | 
CustomPropertiesXml
Provides access to the XML document which holds the document's custom properties
Declaration
public XmlDocument CustomPropertiesXml { get; }
  Property Value
| Type | Description | 
|---|---|
| System.Xml.XmlDocument | 
ExtendedPropertiesXml
Provides access to the XML document that holds the extended properties of the document (app.xml)
Declaration
public XmlDocument ExtendedPropertiesXml { get; }
  Property Value
| Type | Description | 
|---|---|
| System.Xml.XmlDocument | 
HyperlinkBase
Gets/sets the HyperlinkBase property of the document (extended property)
Declaration
public Uri HyperlinkBase { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.Uri | 
HyperlinksChanged
Hyperlinks need update
Declaration
public bool HyperlinksChanged { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.Boolean | 
Keywords
Gets/sets the keywords property of the document (core property)
Declaration
public string Keywords { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.String | 
LastModifiedBy
Gets/sets the lastModifiedBy property of the document (core property)
Declaration
public string LastModifiedBy { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.String | 
LastPrinted
Gets/sets the lastPrinted property of the document (core property)
Declaration
public string LastPrinted { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.String | 
LinksUpToDate
Indicates whether hyperlinks in a document are up-to-date
Declaration
public bool LinksUpToDate { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.Boolean | 
Manager
Gets/sets the Manager property of the document (extended property)
Declaration
public string Manager { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.String | 
Modified
Gets/sets the modified property of the document (core property)
Declaration
public DateTime Modified { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.DateTime | 
ScaleCrop
Display mode of the document thumbnail. True to enable scaling. False to enable cropping.
Declaration
public bool ScaleCrop { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.Boolean | 
SharedDoc
If true, document is shared between multiple producers.
Declaration
public bool SharedDoc { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.Boolean | 
Status
Gets/sets the status property of the document (core property)
Declaration
public string Status { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.String | 
Subject
Gets/sets the subject property of the document (core property)
Declaration
public string Subject { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.String | 
Title
Gets/sets the title property of the document (core property)
Declaration
public string Title { get; set; }
  Property Value
| Type | Description | 
|---|---|
| System.String | 
Methods
GetCustomPropertyValue(String)
Gets the value of a custom property
Declaration
public object GetCustomPropertyValue(string propertyName)
  Parameters
| Type | Name | Description | 
|---|---|---|
| System.String | propertyName | The name of the property  | 
      
Returns
| Type | Description | 
|---|---|
| System.Object | The current value of the property  | 
      
GetExtendedPropertyValue(String)
Get the value of an extended property
Declaration
public string GetExtendedPropertyValue(string propertyName)
  Parameters
| Type | Name | Description | 
|---|---|---|
| System.String | propertyName | The name of the property  | 
      
Returns
| Type | Description | 
|---|---|
| System.String | The value  | 
      
SetCustomPropertyValue(String, Object)
Allows you to set the value of a current custom property or create your own custom property.
Declaration
public void SetCustomPropertyValue(string propertyName, object value)
  Parameters
| Type | Name | Description | 
|---|---|---|
| System.String | propertyName | The name of the property  | 
      
| System.Object | value | The value of the property  | 
      
SetExtendedPropertyValue(String, String)
Set the value for an extended property
Declaration
public void SetExtendedPropertyValue(string propertyName, string value)
  Parameters
| Type | Name | Description | 
|---|---|---|
| System.String | propertyName | The name of the property  | 
      
| System.String | value | The value  |