Class NSDocumentTemplateEntity

The template a document is based on is stored in the SO arc\template folder on the server. This will return the name as displayed in the GUI, and not the physical document name, of the template the document object is based on.

Constructors

NSDocumentTemplateEntity()

Initializes a new instance of the NSDocumentTemplateEntity class.

Declaration

NSDocumentTemplateEntity

Methods

GetAutoeventId()

Which document plugin is responsible for the documents generated from this template

Declaration

Integer GetAutoeventId()

Examples

NSDocumentTemplateEntity thing;
Integer autoeventId = thing.GetAutoeventId();

Returns

Type Description
Integer

GetDefaultOref()

Processed via tag substitution to give document reference

Declaration

String GetDefaultOref()

Examples

NSDocumentTemplateEntity thing;
String defaultOref = thing.GetDefaultOref();

Returns

Type Description
String

GetDeleted()

True if deleted

Declaration

Bool GetDeleted()

Examples

NSDocumentTemplateEntity thing;
Bool deleted = thing.GetDeleted();

Returns

Type Description
Bool

GetDirection()

Declaration

Integer GetDirection()

Examples

NSDocumentTemplateEntity thing;
Integer direction = thing.GetDirection();

Returns

Type Description
Integer 1 = incoming, 2 = outgoing. See <xref href="CRMScript.NetServer.TaskDirection" data-throw-if-not-resolved="false"></xref>

GetDocumentTemplateId()

Primary key

Declaration

Integer GetDocumentTemplateId()

Examples

NSDocumentTemplateEntity thing;
Integer documentTemplateId = thing.GetDocumentTemplateId();

Returns

Type Description
Integer

GetDocumentTypeKey()

The document type to use when creating a blank document. Plugin-specific. Used when not creating template from a local file.

Declaration

Integer GetDocumentTypeKey()

Examples

NSDocumentTemplateEntity thing;
Integer documentTypeKey = thing.GetDocumentTypeKey();

Returns

Type Description
Integer

GetEmailSubject()

Subject to use if document template is an email.

Declaration

String GetEmailSubject()

Examples

NSDocumentTemplateEntity thing;
String emailSubject = thing.GetEmailSubject();

Returns

Type Description
String

GetFilename()

Relative to TemplatePath, or extref for other document plugins. i.e URL or full path.

Declaration

String GetFilename()

Examples

NSDocumentTemplateEntity thing;
String filename = thing.GetFilename();

Returns

Type Description
String

GetIncludeSignature()

True if the email signature should be added in bottom of mail if this an email template

Declaration

Bool GetIncludeSignature()

Examples

NSDocumentTemplateEntity thing;
Bool includeSignature = thing.GetIncludeSignature();

Returns

Type Description
Bool

GetIntentId()

What is the intention of this document (used by SAINT)

Declaration

Integer GetIntentId()

Examples

NSDocumentTemplateEntity thing;
Integer intentId = thing.GetIntentId();

Returns

Type Description
Integer

GetInvitationDocType()

Declaration

Integer GetInvitationDocType()

Examples

NSDocumentTemplateEntity thing;
Integer invitationDocType = thing.GetInvitationDocType();

Returns

Type Description
Integer Type for sending email meeting invitation. See <xref href="CRMScript.NetServer.DocTmplInvitationType" data-throw-if-not-resolved="false"></xref>

GetIsDefaultPublished()

Declaration

Bool GetIsDefaultPublished()

Examples

NSDocumentTemplateEntity thing;
Bool isDefaultPublished = thing.GetIsDefaultPublished();

Returns

Type Description
Bool Published to external persons.

GetIsInUseInGuides()

True if the template is in use in a project or sales guide

Declaration

Bool GetIsInUseInGuides()

Examples

NSDocumentTemplateEntity thing;
Bool isInUseInGuides = thing.GetIsInUseInGuides();

Returns

Type Description
Bool

GetLoadTemplateFromPlugin()

Which document plugin is responsible for this template's contents

Declaration

Integer GetLoadTemplateFromPlugin()

Examples

NSDocumentTemplateEntity thing;
Integer loadTemplateFromPlugin = thing.GetLoadTemplateFromPlugin();

Returns

Type Description
Integer

GetMimeType()

The mime type

Declaration

String GetMimeType()

Examples

NSDocumentTemplateEntity thing;
String mimeType = thing.GetMimeType();

Returns

Type Description
String

GetName()

The template list item

Declaration

String GetName()

Examples

NSDocumentTemplateEntity thing;
String name = thing.GetName();

Returns

Type Description
String

GetPrivacyDocType()

Declaration

Integer GetPrivacyDocType()

Examples

NSDocumentTemplateEntity thing;
Integer privacyDocType = thing.GetPrivacyDocType();

Returns

Type Description
Integer Indicator that this document template has a functional role, related to privacy/GDPR. See <xref href="CRMScript.NetServer.DocTmplPrivacyType" data-throw-if-not-resolved="false"></xref>

GetQuoteDocType()

Declaration

Integer GetQuoteDocType()

Examples

NSDocumentTemplateEntity thing;
Integer quoteDocType = thing.GetQuoteDocType();

Returns

Type Description
Integer The role this document plays in the Quote system, if any. See <xref href="CRMScript.NetServer.DocTmplQuoteType" data-throw-if-not-resolved="false"></xref>

GetRank()

Declaration

Integer GetRank()

Examples

NSDocumentTemplateEntity thing;
Integer rank = thing.GetRank();

Returns

Type Description
Integer Rank order.

GetRecordType()

Declaration

NSDocTmplType GetRecordType()

Examples

NSDocumentTemplateEntity thing;
NSDocTmplType recordType = thing.GetRecordType();

Returns

Type Description
NSDocTmplType 1 = app, 2 = doc, 3 = email, 4 = fax, 5 = phone, 6 = todo See <xref href="CRMScript.NetServer.TaskType" data-throw-if-not-resolved="false"></xref>

GetSaveInDb()

1 = save document records in DB; otherwise not.

Declaration

Integer GetSaveInDb()

Examples

NSDocumentTemplateEntity thing;
Integer saveInDb = thing.GetSaveInDb();

Returns

Type Description
Integer

GetSenderEmailAddress()

If email template, default sender address when template is of type quote email or privacy email.

Declaration

String GetSenderEmailAddress()

Examples

NSDocumentTemplateEntity thing;
String senderEmailAddress = thing.GetSenderEmailAddress();

Returns

Type Description
String

GetSenderEmailMode()

Declaration

Integer GetSenderEmailMode()

Examples

NSDocumentTemplateEntity thing;
Integer senderEmailMode = thing.GetSenderEmailMode();

Returns

Type Description
Integer If email template, when DocType is Privacy or quote email, it is possible to make sender address like our contact, or our support contact, or always one address. See <xref href="CRMScript.NetServer.SenderMailMode" data-throw-if-not-resolved="false"></xref>

GetShowCurrents()

True if when using this template there should be shown a place for editing current choices of person, compant, sale, project etc

Declaration

Bool GetShowCurrents()

Examples

NSDocumentTemplateEntity thing;
Bool showCurrents = thing.GetShowCurrents();

Returns

Type Description
Bool

GetTooltip()

Tooltip or other description

Declaration

String GetTooltip()

Examples

NSDocumentTemplateEntity thing;
String tooltip = thing.GetTooltip();

Returns

Type Description
String

SetAutoeventId(Integer)

Which document plugin is responsible for the documents generated from this template

Declaration

Void SetAutoeventId(Integer autoeventId)

Examples

NSDocumentTemplateEntity thing;
Integer autoeventId;
thing.SetAutoeventId(autoeventId);

Parameters

Type Name Description
Integer autoeventId

Returns

Type Description
Void

SetDefaultOref(String)

Processed via tag substitution to give document reference

Declaration

Void SetDefaultOref(String defaultOref)

Examples

NSDocumentTemplateEntity thing;
String defaultOref;
thing.SetDefaultOref(defaultOref);

Parameters

Type Name Description
String defaultOref

Returns

Type Description
Void

SetDeleted(Bool)

True if deleted

Declaration

Void SetDeleted(Bool deleted)

Examples

NSDocumentTemplateEntity thing;
Bool deleted;
thing.SetDeleted(deleted);

Parameters

Type Name Description
Bool deleted

Returns

Type Description
Void

SetDirection(Integer)

Sets the direction of a document template.

Declaration

Void SetDirection(Integer direction)

Examples

NSDocumentTemplateEntity thing;
Integer direction;
thing.SetDirection(direction);

Parameters

Type Name Description
Integer direction See <xref href="CRMScript.NetServer.TaskDirection" data-throw-if-not-resolved="false"></xref>.

Returns

Type Description
Void

SetDocumentTemplateId(Integer)

Primary key

Declaration

Void SetDocumentTemplateId(Integer documentTemplateId)

Examples

NSDocumentTemplateEntity thing;
Integer documentTemplateId;
thing.SetDocumentTemplateId(documentTemplateId);

Parameters

Type Name Description
Integer documentTemplateId

Returns

Type Description
Void

SetDocumentTypeKey(Integer)

The document type to use when creating a blank document. Plugin-specific. Used when not creating template from a local file.

Declaration

Void SetDocumentTypeKey(Integer documentTypeKey)

Examples

NSDocumentTemplateEntity thing;
Integer documentTypeKey;
thing.SetDocumentTypeKey(documentTypeKey);

Parameters

Type Name Description
Integer documentTypeKey

Returns

Type Description
Void

SetEmailSubject(String)

Subject to use if document template is an email.

Declaration

Void SetEmailSubject(String emailSubject)

Examples

NSDocumentTemplateEntity thing;
String emailSubject;
thing.SetEmailSubject(emailSubject);

Parameters

Type Name Description
String emailSubject

Returns

Type Description
Void

SetFilename(String)

Relative to TemplatePath, or extref for other document plugins. i.e URL or full path.

Declaration

Void SetFilename(String filename)

Examples

NSDocumentTemplateEntity thing;
String filename;
thing.SetFilename(filename);

Parameters

Type Name Description
String filename

Returns

Type Description
Void

SetIncludeSignature(Bool)

True if the email signature should be added in bottom of mail if this an email template

Declaration

Void SetIncludeSignature(Bool includeSignature)

Examples

NSDocumentTemplateEntity thing;
Bool includeSignature;
thing.SetIncludeSignature(includeSignature);

Parameters

Type Name Description
Bool includeSignature

Returns

Type Description
Void

SetIntentId(Integer)

What is the intention of this document (used by SAINT)

Declaration

Void SetIntentId(Integer intentId)

Examples

NSDocumentTemplateEntity thing;
Integer intentId;
thing.SetIntentId(intentId);

Parameters

Type Name Description
Integer intentId

Returns

Type Description
Void

SetInvitationDocType(Integer)

Declaration

Void SetInvitationDocType(Integer invitationDocType)

Examples

NSDocumentTemplateEntity thing;
Integer invitationDocType;
thing.SetInvitationDocType(invitationDocType);

Parameters

Type Name Description
Integer invitationDocType The role this document plays in the Quote system, if any. See <xref href="CRMScript.NetServer.DocTmplQuoteType" data-throw-if-not-resolved="false"></xref>.

Returns

Type Description
Void

SetIsDefaultPublished(Bool)

Published to external persons

Declaration

Void SetIsDefaultPublished(Bool isDefaultPublished)

Examples

NSDocumentTemplateEntity thing;
Bool isDefaultPublished;
thing.SetIsDefaultPublished(isDefaultPublished);

Parameters

Type Name Description
Bool isDefaultPublished

Returns

Type Description
Void

SetIsInUseInGuides(Bool)

True if the template is in use in a project or sales guide

Declaration

Void SetIsInUseInGuides(Bool isInUseInGuides)

Examples

NSDocumentTemplateEntity thing;
Bool isInUseInGuides;
thing.SetIsInUseInGuides(isInUseInGuides);

Parameters

Type Name Description
Bool isInUseInGuides

Returns

Type Description
Void

SetLoadTemplateFromPlugin(Integer)

Which document plugin is responsible for this template's contents

Declaration

Void SetLoadTemplateFromPlugin(Integer loadTemplateFromPlugin)

Examples

NSDocumentTemplateEntity thing;
Integer loadTemplateFromPlugin;
thing.SetLoadTemplateFromPlugin(loadTemplateFromPlugin);

Parameters

Type Name Description
Integer loadTemplateFromPlugin

Returns

Type Description
Void

SetMimeType(String)

The mime type

Declaration

Void SetMimeType(String mimeType)

Examples

NSDocumentTemplateEntity thing;
String mimeType;
thing.SetMimeType(mimeType);

Parameters

Type Name Description
String mimeType

Returns

Type Description
Void

SetName(String)

The template list item

Declaration

Void SetName(String name)

Examples

NSDocumentTemplateEntity thing;
String name;
thing.SetName(name);

Parameters

Type Name Description
String name

Returns

Type Description
Void

SetPrivacyDocType(Integer)

Declaration

Void SetPrivacyDocType(Integer privacyDocType)

Examples

NSDocumentTemplateEntity thing;
Integer privacyDocType;
thing.SetPrivacyDocType(privacyDocType);

Parameters

Type Name Description
Integer privacyDocType Indicator that this document template has a functional role, related to privacy/GDPR. See <xref href="CRMScript.NetServer.DocTmplPrivacyType" data-throw-if-not-resolved="false"></xref>.

Returns

Type Description
Void

SetQuoteDocType(Integer)

Declaration

Void SetQuoteDocType(Integer quoteDocType)

Examples

NSDocumentTemplateEntity thing;
Integer quoteDocType;
thing.SetQuoteDocType(quoteDocType);

Parameters

Type Name Description
Integer quoteDocType The role this document plays in the Quote system, if any. See <xref href="CRMScript.NetServer.DocTmplQuoteType" data-throw-if-not-resolved="false"></xref>.

Returns

Type Description
Void

SetRank(Integer)

Rank order

Declaration

Void SetRank(Integer rank)

Examples

NSDocumentTemplateEntity thing;
Integer rank;
thing.SetRank(rank);

Parameters

Type Name Description
Integer rank

Returns

Type Description
Void

SetRecordType(NSDocTmplType)

1 = app, 2 = doc, 3 = email, 4 = fax, 5 = phone, 6 = todo

Declaration

Void SetRecordType(NSDocTmplType recordType)

Examples

NSDocumentTemplateEntity thing;
NSDocTmplType recordType;
thing.SetRecordType(recordType);

Parameters

Type Name Description
NSDocTmplType recordType

Returns

Type Description
Void

SetSaveInDb(Integer)

1 = save document records in DB; otherwise not.

Declaration

Void SetSaveInDb(Integer saveInDb)

Examples

NSDocumentTemplateEntity thing;
Integer saveInDb;
thing.SetSaveInDb(saveInDb);

Parameters

Type Name Description
Integer saveInDb

Returns

Type Description
Void

SetSenderEmailAddress(String)

If email template, default senderaddress when template is of type quote email or privacy email.

Declaration

Void SetSenderEmailAddress(String senderEmailAddress)

Examples

NSDocumentTemplateEntity thing;
String senderEmailAddress;
thing.SetSenderEmailAddress(senderEmailAddress);

Parameters

Type Name Description
String senderEmailAddress

Returns

Type Description
Void

SetSenderEmailMode(Integer)

Declaration

Void SetSenderEmailMode(Integer senderEmailMode)

Examples

NSDocumentTemplateEntity thing;
Integer senderEmailMode;
thing.SetSenderEmailMode(senderEmailMode);

Parameters

Type Name Description
Integer senderEmailMode If email template, when DocType is Privacy or quote email, it is possible to make sender address like our contact, or our support contact, or always one address. See <xref href="CRMScript.NetServer.SenderMailMode" data-throw-if-not-resolved="false"></xref>.

Returns

Type Description
Void

SetShowCurrents(Bool)

True if when using this template there should be shown a place for editing current choices of person, compant, sale, project etc

Declaration

Void SetShowCurrents(Bool showCurrents)

Examples

NSDocumentTemplateEntity thing;
Bool showCurrents;
thing.SetShowCurrents(showCurrents);

Parameters

Type Name Description
Bool showCurrents

Returns

Type Description
Void

SetTooltip(String)

Tooltip or other description

Declaration

Void SetTooltip(String tooltip)

Examples

NSDocumentTemplateEntity thing;
String tooltip;
thing.SetTooltip(tooltip);

Parameters

Type Name Description
String tooltip

Returns

Type Description
Void