Extract specific data from notpad++

@mironb ,

I believe you have the Network Directory Path, Could you maybe try retrieving the files available in the Network Folder using the below Expression :

Directory.GetFiles("Your Network Directory Path").ToArray

After maybe checking on this, we can introduce further steps on checking the data within the files and searching for the particular number.

Let us know if you knew about this method and have already tried it.

How I can implement this checking ?
Directory.GetFiles(“Your Network Directory Path”).ToArray
I am new in UiPath, Thanks

@mironb ,
You can try with this setup :



Here, filePaths is a Array of String type variable. The “Samplepdfs” is the Folder name, as it is present in the Project Directory itself, I did not have to provide the full folder path.

In the Output Panel, we must be able to get the File paths of the files present in the Samplepdfs folder.

Let us know if you were able to make it work with your Network Directory path



I guess you copy pasted the formula…Please replace the double quotes in the code again…by removing them "


Remove the “” ?
I put my path in “My path”.

It works, but how it can help me ?
This directory is a dynamic one
I need to check it every X seconds until the IDcustomer will appear

@mironb ,

Do you see the file path that contains the number that you want ?

If so, then we would need to include further steps in the Process Developed.

But before that could you confirm what are the file types, what file types are you looking for that has your data or number ? Is it a .txt file ? .xml ?

@mironb ,

For this part, we would again require your help to understand what is the total requirement. Are we really supposed to check every x seconds ? What is the manual process ?

I don’t know in witch batch file (what you found in write line) the specific XML (there is the IDcustomer placed)
Therefore I used the notepad++ - there I paste the ID number and it find me the batch file there is the XML

@mironb ,

Could you give more details of your total process that you want to perform ?

What do you do after we have found the ID number in the xml file ? Do give more details so that we could try to sum up the requirements within a Single post.


I need to read XML that is inside a Batch file (within it there are several merged XMLs).

Since I don’t know in which batch file the same XML is found (it is dynamic) it is created after a new customer is created in the system, so I have to locate the same batch file only through Notepad++
I search by the customer ID number I created and I am shown the following.

What I want is after I pasted the customer number and found it, to read the data of the customer number (actually do verification) from the Notepad++ search result

@mironb ,

For this above mentioned purpose, as said earlier, we can use the below Steps :

  1. Use Directory.GetFiles(“Your Network Path”,“*.xml”) and get the list of all the xml files present in the Folder.

  2. Next, Loop through the files, and read the file using Read Text File activity.

  3. Check if the text data present has the customer ID present in it, specifically in the xml format below :


For this we can use a Regex IsMatch for identifying if it is present or not.

  1. If present within the file, then we get to know which file contains this number, we can then read that file data, or parse that file as XML document and then perform the actions required.

Check the example workflow below:
Files_GetRequiredFile_ForProcessing.zip (4.4 KB)

Output Visuals :

Maybe this part is not clear yet, However I believe when using the Directory.GetFiles() previously you were able to get all the xml files as well.

However, try the workflow and apply it to your requirements and let us know what are your findings.

1 Like


Thank you very mach, it works !!!

1 Like


How can I do verification on this ?

@mironb ,

As also mentioned in previous posts, we do not know your complete process or the task that you are trying to perform, hence we only understood that you would want to find a file that has a customer ID in it.

So we provided an example workflow.

The other requirements as to the verification steps are not known to us yet.

If you have many more steps to be performed, do create a Separate topic on it, So that we can provide help on it separately.

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.