Storing file path as config data in text file

I have an automation that reads from and writes into Excel file in SharePoint location. May I know whether it is possible to store the file path for the Excel file in a text file so that I can change it without modifying my automation?

1 Like


Instead of the file path , you can actually save the folder path in the config. So whenever there is a change in the folder , you can update the config.

Other option is you can use environment folder activity to make it even more dynamic without using config if files are saved in the local folders -


Yes, it’s possible. I would reccomend using arguments instead of config file since you only want to pass one argument.
If you insist with files it’s also possible to use text file but instead of text file I’d reccomend excel file.
The only thing you’ll need to be careful is to place that file in location accessible by all automation users.

  1. Using arguments:
    In your Main.xaml (or whatever workflow you use as main) please add an argument. Define it’s type and direction (as you want to pass path probably string)

  2. Use argument in somewhere in the process.

  3. Please publish the process.

  4. Go into UiPath assistant and find the published process. It will have a field to input the argument.

  5. Write whatever value you want there.

2. Using Files

  1. Drag and drop “Read Text File” activity for txt files or “Read Range Workbook” for excel files.

  2. Provide path to your file.

  3. Use the read path.