Home Search

DriveWorks Pro 22
Write A Line Of Text To The End Of A Text File

Send Feedback

Write A Line Of Text To The End Of A Text File

This Specification task will write a line of text to the end of a text file (append).

Any additonal text to be added will be inserted into a new line.

Properties

Property NameDescription
TitleChanges the Title (not the name) of the task.
TextThe text to write (append) to the text file. (On a new line).
Text FileThe full path, including extension, of the file that the text will be written to.

Example

When this Task is added the properties are static. To be able to build rules on a static property see How To: Change A Static Property To A Dynamic Property.

Property NameExample RuleExample ResultMeaning
Text"DriveWorksSpecNo "&DWSpecificationIdDriveWorksSpecNo 9999This is the text that will be inserted into the text document.
Text file"C:\MyDocuments\SpecRecord.txt"C:\MyDocuments\SpecRecord.txtThis is the full file path to the text document to add the text to.

Example Result

Example Text File

DriveWorksSpecNo1

DriveWorksSpecNo2

DriveWorksSpecNo3

Using the Task in a Specification Macro

This task has different types of Outputs. For more information about Outputs see Specification Macros Task Node.

Outputs are only available within Specification Macros. Currently Outputs are not available for Specification Flow.

Status Outputs

This task supports Status Outputs. These can be used to perform different actions depending on what the status outcome of the task is. For more information see Status Outputs in the Task Node Outputs section of Specification Macros Task Node.

The status output navigation is as follows:

Success

  • The Text was successfully added to the text file.

Success with Warnings

  • N/A - should never be fulfilled.

Failed (one of the following occurred)

  • User does not have edit permissions for the chosen file.
  • Text File path is blank.
  • File path is invalid.