You are here: PSPad forum > English discussion forum > delete a text file all drive letters
Posted by: maki | Date: 2014-12-30 19:15 | IP: IP Logged
how to delete a text file all drive letters
example:
C:\My Documents\.....
D:\name....
remove only all letter
C:\
D:\
E:\
...
Z:\
etc.
Edited 2 time(s). Last edit at 2014-12-30 19:16 by maki.
Posted by: pspad | Date: 2014-12-30 19:32 | IP: IP Logged
You looks you are very lazy boy. After all advices related to regular expressions you should be able to have some basics
Search: ^\w\:\\
Replace:
[x]Regular expressions
Posted by: maki | Date: 2015-01-01 15:50 | IP: IP Logged
Not work Regex
Posted by: Stefan | Date: 2015-01-01 16:45 | IP: IP Logged
If the drive letter is NOT at begin of line, better use
Search: \w:\\
Replace:
[x]Regular expressions
instead.
--
Stefan (pleased user since 1722)
Do you know you can spend Jan a beer? (click here)
Inofficial FAQs + Infos + Special Settings
Edited 1 time(s). Last edit at 2015-01-01 16:47 by Stefan.
Posted by: pspad | Date: 2015-01-01 16:50 | IP: IP Logged
maki:Not work Regex
I am working with examples you provided. If your lines are different in the real, it's your problem, not mine. Test my answer with example you gave me, then answer it's not working.
I think you make a fun of us. Maybe will be better spend time with something more useful, than waste it with answer of your topics, right?
My regular expression works with your screenshot:
c:\12345
Edited 1 time(s). Last edit at 2015-01-01 16:52 by pspad.
Posted by: maki | Date: 2015-01-01 16:51 | IP: IP Logged
Stefan - Now it works fine
Edited 3 time(s). Last edit at 2015-01-01 16:57 by maki.
Posted by: pspad | Date: 2015-01-01 16:57 | IP: IP Logged
It means Maki, your path doesn't start on the begin of line. Why do you give us example where line start with drive?
Posted by: maki | Date: 2015-01-01 17:02 | IP: IP Logged
pspad - Yes, it works your regex. Sorry. I do not know why I always adds an empty line(space)
Editor PSPad - freeware editor, © 2001 - 2024 Jan Fiala, Hosted by Webhosting TOJEONO.CZ, design by WebDesign PAY & SOFT, code Petr Dvořák, Privacy policy and GDPR