I have some folder like
Folder. artist A [mixed]
Folder. artist B (mixed)
I have some files like
file. artist A (1).flac
file. artist B [remixed].mp4
I need a button for copy the folders and files names only into the clipboard but Ignore all kinds of extension and Ignore everything what is inside in first bracket () and second bracket [] in files and folder names.
Expected Result in folder name is
Folder. artist A
Folder. artist B
Expected Result in folder name is
file. artist A
file. artist B
Thanks Dear pctechtv for helping me. But This button Copy All the folder path also what I don't want, I want only file or folder names.
Example 1 for FOLDER NAME: "Folder Name A [Demo]" is a folder and it's location is:
D:\Project Secure\Backup v.1 [03-11-2018]\Folder Name A [Demo]
What This button Does :
D:\Project Secure\Backup v.1 [03-11-2018]\Folder Name A
What I want as the result is:
Folder Name A
Example 2 for File NAME: "File Name A [Demo].mp3" is a File and it's location is:
D:\Project Secure\Backup v.1 [03-11-2018]\Folder Name A [Demo]\File Name A [Demo].mp3
What This button Does :
D:\Project Secure\Backup v.1 [03-11-2018]\Folder Name A [Demo]\File Name A [Demo]
See All The path is copied.
What I want as the result is:
File Name A
Thank you again Dear pctechtv. here is you feedback.
Feedback 1 for Folder Name:
original path is:
D:\Project Secure\Backup v.1 [03-11-2018]\Folder name A [test]
what the button does:
D:\Project Secure\Backup v.1 [03-11-2018]\Folder name A
What I want is: Folder name A
Feedback 2 for Files Name:
original path is:
D:\Project Secure\Backup v.1 [03-11-2018]\Folder name A [test]\File name A [test] - demo.txt
what the button does:
D:\Project Secure\Backup v.1 [03-11-2018]\Folder name A [test]\File name A
What I want is: File name A
Dear Jon I try your code, But your code is not work also. its paste the whole code line only.
what the button does: Clipboard COPYNAMES=nopaths REGEXP "(.+)\(|\[.+\)|\]" "\1"
What I want as result is: "file name A"
Is that correct? That contradicts what the first post said:
I'm not sure if you want to remove what's inside [...] and (...) or if you want to remove everything after the first [ or ( including things outside of the brackets.
Are 1 & 2 strict requirements, as in if a folder is named Test.txt it'd be a problem to remove the .txt from it?
It would probably require a script to apply different search & replace logic to files vs folders. But if you aren't expecting/concerned about folders with dots in their names then it's easier and shouldn't need a script.
Thanks for Replay dear Leo. "Are 1 & 2 strict requirements" Yes it is. But their is nothing to worry in folder name about 'dots'. Dots is only problem in the file name only for their Extension. So it should easier as you tell.
Or this, which does the same thing but removes (...) and [...] using two separate regex instead of a combined one, which might be easier to read. Or not.
Original Folder name: ABCD [test]
After Using This Code: ABCE
Feed Back: here is a extra Space also paste After the folder name "ABCE (space)" which I don't want. If possible plz remove the extra Space & fix That code.
Original File Name : ABCE (test).txt
After Using This Code: ABCE .txt
Feed Back: Big problem is here is the File Extension. another problem is the extra space After the File name Like the Folder name. Please Remove The File extension & the extra Space with fix the code.