Customizing the email filename format

 

note

 Configurable only via the configuration update process


The format of the filename that is created when transferring email messages can be modified.

 

The default filename format will use the email subject and append an underscore to create a unique hashcode based on the email sent date/time encoded as Base64 text(eg. ACME project information_vf65c8).


OnePlaceMail provides you with the option of choosing one of our predefined standard email filename formats or alternatively creating your own custom format.


The following filename formats are available :

Filename Format

Example

Description 

default:

<email subject>_<hashcode(email sent date/time )>

ABC project information_vf65bmt2

Prevents duplicate emails being filed
within a library (across all users)


Adds minimal additional length to
subject

title_datecurrentuser:


<email subject>_<hashcode(email sent date/time + unique characters to user filing)>

ACME project information_vf65bmt2

Prevents a single user filing duplicate
emails within a library


Adds minimal additional length to
subject

senton_sendername_title:

<email sent date>_<email senttime>_<email sender>_<email subject> 
 

2008-10-24_21-01-23_Jim Smith_WeeklyProject Update

Prevents duplicate emails being filed
within a library (across all users)
Provides legible date/time/sender
information in subject

 

Allows chronological sort of email by
subject


Adds additional length to subject

custom

[sentdateutc#yyyy-MM-dd_HH-mm-ss]_[sendernamesubject#49#]_[subject]_[sentdateutc#yyyy-MM-dd]

Allows you to specify your own
custom format based on predefined

tokens

Explained further below

tip

Note: If filing a draft email, all file formats use the email creation date/time (rather than the sent date/time) and the current user name rather than the sender name.

 

To use an alternate email filename format, use the <filenameMethod> tag which must be inserted within <outlook> tags.


Property

Mandatory / Optional

Description

action

Mandatory

Set to "insert" to change the default behavior
Set to "delete" to revert to default behavior 

value

Mandatory

Valid values:
"senton_sendername_title"
"title_datecurrentuser"
"custom"

customFileFormat

Mandatory if using custom format

If using "custom" in value attribute above specifies the custom filename format based upon predefined token values

maximumFileNameLength

Optional

Allows you to specify the maximumFileNameLength if using  the email subject in the filename.


Example: Use <email sent date>_<email sent time>_<email sender>_<email subject> format.

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <outlook>
        <filenameMethod action="delete"/>
        <filenameMethod value="senton_sendername_title" action="insert"/>
    </outlook>
</configuration>

 


Example : Revert the filename format back to the default

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <outlook>
        <filenameMethod action="delete"/>
    </outlook>
</configuration>

 

 

Example :User <email_subject>_<unique characters to user> format

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <outlook>
        <filenameMethod action="delete"/>
        <filenameMethod action="insert" value="title_datecurrentuser"/>
    </outlook>
</configuration> 

 

 

Custom Email Filename formats

Custom Filename Formats allow you to create your own filename format.

Please find several predefined tokens in the table below. Any combination of these tokens can be used and the tokens can be added to any filename you provide – the tokens are replaced by the actual values taken dynamically from the email.

Tokens allow you to specify additional optional parameters which must be prefixed with #.


Token

Mandatory / Optional

Parameters

Description

[sentdatelocal]

Optional

datetimeformatstring

Uses the local date time of the users ’ current time zone in the email filename for the sent date.

Examples:

[sentdatelocal]
uses the default date time - format string "yyyy-MM-dd_HH-mm-ss"


[sentdatelocal#yyyy-MM-dd]
uses a custom datetime format which includes only the year, month and day of the email sent date.

It is important to note that using the local date time of the user can cause duplicate emails to be saved.

Only datetime separators that are valid in filenames are supported

Example: HH-mm-ss not HH:mm:s s as ':' is not supported in filenames.

[sentdateutc]

Optional

datetimeformatstring

Uses the UTC datetime of the sentdate in the email filename.

Examples:

[sentdatelocal] uses the default date time format string "yyyy-MM-dd_HH-mm-ss"


[sentdatelocal#yyyy-MM-dd] uses a custom datetime format which includes only the year, month and day of the email sent date.

 

It is important to note that using the UTC date time helps prevent duplicate emails being saved to the same location in SharePoint.

[sendernamesubject]

Mandatory

maxlength separator

Uses a combination of the sender and subject and a separator character to separate the values.

The maxlength specifies the maximum length of the sender and subject combined. .

Examples:

[sendernamesubject#49#-]
[sendernamesubject#60#_]

[subject]

Optional

maxlength

The email senders name.

Examples:
[subject]
The default is to return the entire senders name.


[subject#10]
The subject length of 10 characters

 

Note: the maxlength that can be defined is 198 characters.

[sendername]

Optional

maxlength

Unique hash code for email based on the sent datetime of the email. Useful in combination with the email subject and sender.

[uniquehash]

N/A

N/A

Unique hash code for email based on the sent datetime of the email. Useful in combination with the email subject and sender.

[uniquehashuser]

N/A

N/A

Unique hash code for email based on the sent datetime of the email plus the initials of the person filing the email


Example filenames using prefix


CompanyPrefix_[subject]_[sendername]_[uniquehash]

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <outlook>
        <filenameMethod action="delete"/>
        <filenameMethod value="custom" customFileFormat="CompanyPrefix_[subject]_[sendername]_[uniquehash]" action="insert"/>
    </outlook>
</configuration>

 


Example: [subject]-[sendername]-[sentdateutc#yyyy-MM-dd]

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <outlook>
        <filenameMethod action="delete"/>
        <filenameMethod value="custom" customFileFormat="[subject]-[sendername]-[sentdateutc#yyyy-MM-dd]" action="insert"/>
    </outlook>
</configuration>

 


Example:CompanyPrefix_[sendername]_[subject]_[uniquehash]_CompanyText

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <outlook>
        <filenameMethod action="delete"/>
        <filenameMethod value="custom" customFileFormat="CompanyPrefix_[sendername]_[subject]_[uniquehash]_CompanyText" action="insert"/>
    </outlook>
</configuration>

 

 

Example: Prefix123_[sendernamesubject#50#_]_[uniquehash]_ProjectEmail 

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <outlook>
        <filenameMethod action="delete"/>
        <filenameMethod value="custom" customFileFormat="Prefix123_[sendernamesubject#50#_]_[uniquehash]_ProjectEmail" action="insert"/>
    </outlook>
</configuration>

 

 

Example: [sentdateutc#yyyy]_[subject#50]

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <outlook>
        <filenameMethod action="delete"/>
        <filenameMethod value="custom" customFileFormat="Prefix123_[sendernamesubject#50#_]_[uniquehash]_ProjectEmail" action="insert"/>
    </outlook>
</configuration>

 

 

Example: [subject]_[sentdateutc#dd-MM-yyyy]

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <outlook>
        <filenameMethod action="delete"/>
        <filenameMethod value="custom" customFileFormat="[subject]_[sentdateutc#dd-MM-yyyy]" action="insert"/>
    </outlook>
</configuration>


 


Further custom Date / Time format strings can be found via the following Microsoft article: http://msdn.microsoft.com/enus/library/8kb3ddd4(v=vs.110).aspx