Print

ChangeAttachmentName

The ChangeAttachmentName() function changes the name of the attached file with the provided name to the new one.

Syntax

ChangeAttachmentName(sourceFileName,newFileName);

Function arguments

  • sourceFileName – (String) a name of the attached file for which name is to be changed;
  • newFileName – (String) a new name for the attached file.

Return value

The ChangeAttachmentName() function returns Boolean.
Returns true if change was successful, otherwise false.

Examples

Example 1

This will change name of 'currentName’ to 'newName’.

ChangeAttachmentName("currentName","newName");

Example 2

This will change name of attachment based on values stored in [currName] and [newName] variables.

ChangeAttachmentName([currName], [newName]);

Example 3

This will change name of 'doc_template.docx’ to 'ClientNameValue_info.docx’. (ClientNameValue is the value stored in [ClientName] variable).

ChangeAttachmentName("doc_template.docx",[ClientName]+"_info.docx");
Czy artykuł był pomocny?
0 na 5 gwiazdek
5 Stars 0%
4 Stars 0%
3 Stars 0%
2 Stars 0%
1 Stars 0%
5
How can we improve this article?
How Can We Improve This Article?