One moment please...
 
Exact Synergy Enterprise   
 

How-to: Using Hyperlink to Create Document with Prefilled Properties

How-to: Using Hyperlink to Create Document with Prefilled Properties

Introduction

You can insert a hyperlink in a document that will open the document editor with a new document when clicked. In this hyperlink, you can pass several parameters that specify the type of document to be created as well as prefill some properties in the new document.

This method is especially useful in situations such as:

  • To make it easy for employees reading a policy document to create documents with correct properties such as for meeting notes or web publication, and
  • To collect extensive feedback from readers using documents linked to the specific request, project, and item.

By prefilling properties of a new document, you can also reduce the errors associated with users specifying incorrect properties such as wrong type, projects, or items.

Note: This document assumes you are familiar with URL and web hyperlinks, as well as Exact Synergy Enterprise documents.

Description

Topics in this document:

Building the hyperlink

In order to create documents with prefilled properties using a hyperlink, you need to first build the URL for the hyperlink. In this URL, you can specify the relevant parameters and values. The basic URL is in the following form:

scheme://authority/path/docs/DocDocumentEdit.aspx?BCAction=0&query

where:

  • scheme is "http" or "https" depending on your server configuration
  • authority is normally the domain name of your Exact Synergy Enterprise server
  • path is where Exact Synergy Enterprise is accessible in your server, and
  • query contains the parameters and values to pass to the document editor.

Notice that the first parameter, "BCAction", is included in the URL as it is a mandatory parameter. The parameter and value pairs are to be separated by ampersands ("&"). For simplicity, the following basic URL will be used in examples throughout this document:

https://exactsynergy.com/synergy/docs/DocDocumentEdit.aspx?BCAction=0

Document parameters

You can use only parameters relevant to the document type being created. If a specified parameter is not used by the document type, the parameter and value will be ignored. Whenever a parameter or value is not specified, the field will be left blank or prefilled with the default value defined in the document type or category where applicable.

Basic parameters to create documents

The easiest way to specify the basic parameter to create a new document is to copy the URL from the Exact Synergy Enterprise interface, as outlined in the following method:

  1. Go to Documents/Entry/Entry/Document: New.
  2. Under Criteria, select Category or Type at Show depending on whether you are planning for the new document to be based on document type or document categories.
  3. Where you would usually click to create a document (subcategory or type), right-click instead and select Properties. The following is a sample Properties screen (subcategory):
    Sample Properties screen
  4. In the Properties window, right-click the text next to the document icon and select Select All.
  5. Then, right-click on the selected text and select Copy.
  6. You may want to add more parameters later to this URL for prefilling other document properties. To make it easier, paste the copied URL into a plain text editor and save the text file if desired.

For more details, the following table lists the parameters to create a document using a hyperlink:

Parameter

Value

Result

Explanation

BCAction

0

Creates a document

This parameter is mandatory and the value specified must be "0" in order to create a document.

Type

Document type ID

Selects the document type

This parameter specifies the document type to create. The expected value is a number that corresponds to the ID of the document type in the system. If "Type" is not specified, the new document will be created based on the document category instead.

Note: When "Type" is specified, "Group", "Category", and "Subcategory" will be ignored. In this case, the new document will use the default categories specified in the document type definition. If document category is not defined for the document type, the last category used by the user clicking the hyperlink will be used.

Group

Document main category ID

Selects the main category of the document

This parameter specifies the main category for the new document. The expected value is a number that corresponds to the ID of the document main category. If "Group" is not specified, the first main document category will be used.

Note: If "Category" is specified, a valid "Group" must be specified to ensure the Category property of the new document is valid.

Category

URL-encodedii document category name

Selects the category of the document

This parameter specifies the category for the new document. The expected value is the name of the category. For category names containing spaces and special characters, you must specify the name in URL-encoded format. For example, replace spaces with "+" and ampersands (&) with "%26".

Note: If "Subcategory" is specified, a valid "Category" must be specified to ensure the Category property of the new document is valid. At the same time, the category specified must be valid within the selected main category.

Subcategory

URL-encodedii document subcategory name

Selects the subcategory of the document

This parameter specifies the subcategory for the new document. The expected value is the name of the subcategory. For subcategory names containing spaces and special characters, you must specify the name in URL-encoded format. For example, replace spaces with "+" and ampersands (&) with "%26".

Note: The subcategory specified must be valid within the selected category.

For example, the following URL will open the document editor with a new document of the Customer complaint type when the hyperlink is clicked:

http://exactsynergy.com/synergy/docs/DocDocumentEdit.aspx?BCAction=0&Type=20

Standard parameters to prefill document properties

The following table lists the standard parameters to prefill certain properties in the new document.

Parameter

Value

Result

Explanation

Person

Resource ID

Selects the linked resource

This parameter prefills the Resource property in the new document. The value must be a valid resource ID. If the document type or category does not have the Resource property, this parameter will be ignored.

Note: If the user clicking the hyperlink is an Employee Self Service (ESS) user (see Release 220: Implementing Three User License Types), this parameter is ignored and the Resource property will be set to the resource ID of the ESS user.

Associate

GUIDi

Prefills the Account property

This parameter prefills the Account property of the new document where applicable. The expected value is the GUID of the account. See Finding the GUID or ID below for the procedure on how to locate the GUID of an account. If the GUID is not valid, the Account property is left blank.

Note: Any valid account GUID specified in this parameter will be used, even if the document type specifies a specific account or account criteria as set in the Selection field under the Account section in the document type definition. The created document will be valid and can be saved. Due to this, if your operating procedures require only accounts within the selection limits to be used for the particular document type, ensure that the specified account meets the criteria manually.

Class_01

Assortment number

Selects the assortment

This parameter specifies the Assortment property option to be preselected in the new document. The expected value is the assortment number. To locate this number, go to Logistics/Setup/Assortments and open the assortment definition. The number is shown at Assortment under the General section of the assortment definition.

Item

Item code

Prefills the Item property

This parameter prefills the Item property of the new document. The expected value is the item code as specified at Code under the General section of the item card.

Company

Division code

Prefills the Division property

This parameter prefills the Division property of the new document. The expected value is the division code as specified at Code under the General section of the division card.

ProjectNr

URL-encodedii project code

Prefills the Project property

This parameter prefills the Project property in the new document. For project codes containing spaces and special characters, you must specify the project code in a URL-encoded format. For example, replace spaces with "+" and ampersands (&) with "%26".

Note: As long as the URL-encoded project code is specified, the Project property will be prefilled with the specified project code, regardless of the validity. Due to this, you should manually ensure the URL-encoded project code is valid to allow the document to be saved.

Subject

URL-encodedii text

Prefills the Subject property

This parameter prefills the Subject property in the new document. You can specify a subject text for up to 255 characters (including spaces). For subjects containing special characters (except space), you must specify the subject in a URL-encoded format. For example, replace ampersands (&) with "%26".

ItemSerialNumber

GUIDi

Prefills the Serial number property

This parameter prefills the Serial number property in the new document. The value is the GUID of the serial number. See Finding the GUID or ID below for the procedure on how to locate the GUID of a serial number. The Serial number property will be left blank if the GUID of the serial number is not valid.

Note: The Serial number property is dependent on the Item property. If this parameter is specified, "Item" parameter must also be specified. The GUID of the serial number must fulfill the dependency relationship to the specified item or the value will be considered invalid.

Class_02_1

Release name

Prefills the first Release property

This parameter prefills the first Release property in the new document. The expected value is the release name as shown in the Release property selection after the Assortment property is defined. The release name can also be located by clicking Releases under the Monitor section of the assortment card.

Note: Both Release properties depend on the release availability in the selected Assortment property. Due to this, the "Assortment" parameter must also be specified and the value of the "Class_02_1" parameter must fulfill the dependency relationship. If this dependency is not fulfilled, the first Release property in the new document will display the specified parameter value but the value will be discarded when the document is saved.

Class_02_2

Release name

Prefills the second Release property

This parameter prefills the first Release property in the new document. The expected value is the release name as shown in the Release property selection after the Assortment property is defined. The release name can also be located by clicking Releases under the Monitor section of the assortment card.

Note: Both Release properties depend on the release availability in the selected Assortment property. Due to this, the "Assortment" parameter must also be specified and the value of the "Class_02_1" parameter must fulfill the dependency relationship. If this dependency is not fulfilled, the first Release property in the new document will display the specified parameter value but the value will be discarded when the document is saved.

OpportunityID

Opportunity card ID

Prefills the Opportunity property

This parameter prefills the Opportunity property in the new document. The value is the ID of the opportunity card (not the opportunity code). See Finding the GUID or ID below for the procedure of locating the ID of an opportunity card.

Note: The Opportunity property depends on the Account property and this means that the "Associate" parameter should also be specified. Despite this, the Opportunity property will be prefilled with a validly specified opportunity code regardless of the dependency; even if the Account property is not specified. In case the Account property is not specified, the document cannot be saved until the user selects an account that is linked to the specified opportunity. However, if valid "Associate" and "OpportunityID" parameters are specified, Exact Synergy Enterprise does not check on the dependency and the new document can be saved. Due to this, you should ensure the dependency manually to avoid inconsistent data.

Table notes

  1. GUID: Globally Unique Identifier. See the procedure in Finding the GUID or ID below on how to obtain the relevant GUID.

  2. To help you URL-encode the text, there are several websites available, such as https://www.urlencoder.org/. Type the normal text in the box and click Encode. You can then copy and use the URL-encoded result as the relevant parameter value.

Finding the GUID or ID

The following method can be used to find the GUID of a serial number or account, or the ID of an opportunity card:

  1. Open the card of the relevant entry for viewing. One of the ways to access the relevant card is by searching:
    • For serial numbers, search at Logistics/Reports/Search/Serial numbers and open the relevant serial number.
    • For accounts, search at Customer/Reports/Accounts/Search and open the relevant account.
    • For opportunities, search at Customers/Reports/Opportunity management/Search and open the relevant opportunity card.
  2. Right-click anywhere on the card (except on hyperlinks) and select Properties. The following is a sample Properties screen of an account card.
  3. The GUID or ID is the value in the ID parameter in the URL next to Address: (URL).

If the GUID or ID is not fully visible in the Properties screen due to the length of the URL, you can copy the URL and paste it in a plain text editor for a better view.

Note: For users migrating from Exact Synergy, GUIDs obtained with this method in Exact Synergy Enterprise are already in URL-encoded format and you should not URL-encode the GUID manually anymore as in Exact Synergy.

Example URL for the hyperlink

For example, the following URL will open the document editor with a new document titled "Annual Performance Review", linked to the employee with resource ID "110278", created under the division with division code "402", and saved under the Employee\HRM\Reviews category when the hyperlink is clicked:

https://exactsynergy.com/synergy/docs/DocDocumentEdit.aspx?BCAction=0
&Subject=Annual+Performance+Review&Person=110278&Company=402
&Group=1&Category=HRM&SubCategory=Reviews

Related document

 

     
 Main Category: Support Product Know How  Document Type: Online help main
 Category: On-line help files  Security  level: All - 0
 Sub category: General  Document ID: 17.767.534
 Assortment:  Date: 12-07-2019
 Release:  Attachment:
 Disclaimer