Insert DataTable In Document
AutomatR.Word.Activities.InsertDataTableInDocument
The "Insert DataTable In Document" activity in AutomatR enables you to insert a table, generated from a DataTable variable, into a Word document at a specific position relative to text or a bookmark. This activity provides flexibility in adding structured data to your Word documents.
Properties
Name | Description |
---|---|
Input | |
Data Table | Specifies the DataTable variable containing extracted data from other inbound activities. DataTable variables storing data to be inserted into the Word document. |
Insert Relative To | Specifies whether the data table should be inserted relative to the entire document or a specific piece of text. Options: "Document," "Text." |
Position | Specifies the position where the data table needs to be inserted. Options: "Start," "End" (if inserting relative to the entire document), "Before," "After," "Replace" (if inserting relative to text). |
Text Occurrence | Specifies the occurrences of the specified text relative to which to add the data table. Options: "First," "Last," "Specific," "All." |
Text to Search For | Specifies the text that needs to be searched in the document, and the data table needs to be inserted according to the specified position. String variables containing the search text. |
Index Position | Specifies the index position when Text Occurrence is set to "Specific." Integer variables containing the index position. |
Misc | |
Display Name | Provides a customizable name for the activity displayed in the workflow. Enhances clarity and organization within the automation project. String variables containing the desired display name. |
Optional | |
Delay | Specifies the amount of time (in seconds) to wait before executing the "Insert DataTable In Document" activity. Useful for handling synchronization issues. Integer variables containing the delay duration. Example: If the amount of time is 1000 milliseconds or 1 sec, i.e., 1. |
How to use:
- Drag and drop the "Insert DataTable In Document" activity onto the workflow.
- Configure the properties by specifying the DataTable variable, insertion options, search text, and position.
- Optionally, configure the delay and customize the display name.
- Execute the workflow to insert the specified data table into the Word document.
Example:
Consider an example where the "Insert DataTable In Document" activity is used to add a table containing sales data to a Word document:
Insert DataTable In Document:
Display Name: "Insert Sales Data"
Data Table: salesDataTable
Insert Relative To: "Document"
Position: "End"
In this example, the activity inserts the "salesDataTable" into the Word document at the end.