Hello there,
i have one file path;
“C:\Users\UiPath\Desktop\Home24\559690.PDF”
“559690.PDF” may vary
Example;
“C:\Users\UiPath\Desktop\Home24\232131690.PDF”
How can I get only the pdf name anyway?
Hello there,
i have one file path;
“C:\Users\UiPath\Desktop\Home24\559690.PDF”
“559690.PDF” may vary
Example;
“C:\Users\UiPath\Desktop\Home24\232131690.PDF”
How can I get only the pdf name anyway?
Hi @d.ulutas,
You can get your files into an array.
Then you can do your job in for each. Please try this assign to get pdf files.
Directory.GetFiles("C:\Users\uipath\Desktop\Home24","*.pdf")
Regards.
Ömer
You Could Check with the below Expression :
Path.GetFileName("C:\Users\uipath\Desktop\Home24\232131690.PDF")
Hi @d.ulutas
I’d you want with extension you can try with @supermanPunch expression
If you want without extension try this
Path.GetFileNameWithoutExtension(“C:\Users\uipath\Desktop\Home24\anything.pdf”)
Regards
Sudharsan
Hi @d.ulutas
Try with this expression
Path.GetFileNameWithoutExtension(“C:\Users\uipath\Desktop\Home24\anything.pdf”)
Regards
Gokul