> ## Documentation Index
> Fetch the complete documentation index at: https://docs.abbyy.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Script export profile to UiPath Orchestrator

> Create a script export profile in an ABBYY FlexiCapture Document Definition to push verified data to a UiPath Orchestrator queue via XML or a C# script.

Before creating an export profile, make sure that [the connector assemblies have been added to the document definition](/flexi-capture/connectors/connecting-libraries-ui-path).

In order to export the processing results from FC after verification (a long time after the processing started), or if the image source is FlexiCapture Mobile Client or Scanning Station, you need to configure the export using a script. The result of this export is the creation of a new transaction in a particular Orchestrator queue. All processing results are stored in the transaction as strings in the Specific Data.

To be able to export data from FC to UiPath via the Orchestrator web service, you need to configure a script export profile in the Document Definition.

To create an export profile for UiPath, please do the following:

1. On the Project Setup Station open your FC project.
2. Click **Project →** Document Definitions... to open the list of Document Definitions available for the project, select the Document Definition for which you want to specify new export settings, and click Edit....
3. Click **Document Definition →** Export Settings....
4. Click the Add... button to start the export profile creation wizard.
5. In the Select the Type of Destination step, select Custom export (script) from the Type drop-down list. Leave the other settings unchanged or modify them as described in FC Help. Click **Next**.
6. In the Script Export step, click the Edit Script... button, select **Script Language: C# .Net**, and paste into the script editor one of the two sample scripts that are available in the Samples folder in the UiPath Connector distribution package: **UiPath - ExportScript - Configure by script (Attended service).cs** (please see [Using a script to specify export settings](#script-specify-export) for details) or **UiPath - ExportScript - Configure by XML (Attended service).cs** (please see [Using an XML file to specify export settings](#xml-specify-export) for details). For a detailed description of the export options, see [Specifying export options](/flexi-capture/connectors/up-configuring-a-script-exp-pr).
7. In the Select the Destination Name step, specify a name for your export profile and click **Finish**.
8. The newly created export profile will appear in the list of available export profiles in the export setup dialog box. To make ABBYY FlexiCapture use this profile on Export stage, select the box next to the profile in the **Enabled** column.
9. Click **OK** and close the Document Definition editor. Next, click the **Publish** button to publish your Document Definition.

# <a id="xml-specify-export" />Using an XML file to specify export settings

The advantage of using an XML file is that you don’t have to edit the script code or the Document Definition. All modifications can be made by editing the XML file, which is much simpler than editing the script code. However, the XML file should be located on every FC Processing Station. And you will also have to synchronize it manually on all of the FC stations from which data is to be exported to UiPath.

To specify export settings in an XML file:

1. [Create an export script](/flexi-capture/connectors/creating-an-export-profile-ui-path) in the document definition that contains the sample script **UiPath - ExportScript - Configure by XML (Attended service).cs**. This script gets the export settings from the XML file.
2. Create such an XML file named **\<Project name>\_\<Document Definition name>.xml**. This naming scheme will allow you to have multiple XML files for different Document Definitions.
3. In the registry of the computer with ABBYY FlexiCapture Processing Station, locate HKEY\_LOCAL\_MACHINE\SOFTWARE\ABBYY\FlexiCapture\12.0\Connectors\UiPath. Create new string value and name it "XmlFolder". Then in its value data field specify the path to the folder in which the XML file with export settings was created.
4. In the registry of the computer with ABBYY FlexiCapture Processing Station, locate the HKEY\_LOCAL\_MACHINE\SOFTWARE\ABBYY\FlexiCapture\12.0\Connectors\ and create new string value and name it "UiPath". Set its value data field as **true.**

<Note>
  If you do not have the necessary keys in the HKEY\_LOCAL\_MACHINE \ SOFTWARE registry branch, create them.
</Note>

<Note>
  As an example of a configuration XML file with detailed comments, please see **default.config.xml** file that is located in the Sample folder in the UIPATH distribution package.
</Note>

<Note>
  In the code of **UiPath - ExportScript - Configure by XML (Attended service).cs**, you can also find some other possible naming schemes for your XML files.
</Note>

# <a id="script-specify-export" />Using a script to specify export settings

The advantage of using a script is that all the export settings will be automatically used by all the FC stations from which data are exported to UiPath. When using an XML file, you can only specify static settings, whereas scripts allow you to specify different file naming rules, file locations, and field mappings depending on the data contained in the exported document.

When working with FC Cloud, you also need to use a script to specify export settings, since FC Cloud does not provide the ability to store an XML file with configuration on Processing Stations.

However, to modify the export settings, you will have to make changes to the script and, consequently, publish a new version of the Document Definition.

Please use the script named **UiPath - ExportScript - Configure by script (Attended service).cs** from the connector files.
