hi,
i'm new to RegEx and i'm wondering:
how can i search for all .docx and .pdf files except the ones whose name ends in 4 digits preceeded by a dot?
this is what i've worked out so far:
\.(docx|pdf)$
finds all .docx and .pdf files
\.\d{4}\.(docx|pdf)$
finds all .docx and .pdf files whose name ends in 4 digits preceeded by a dot
- can these be improved/simplified?
- how can these be combined into one search in order to only find .docx and .pdf files whose name doesn't end in 4 digits preceeded by a dot?
Thanks in advance!
RegEx search with omission
Moderators: Hacker, petermad, Stefan2, white
Re: RegEx search with omission
(?<!\.\d{4})\.(docx|pdf)$
Re: RegEx search with omission
That seems to produce an error:
TRegExprW(comp):Urecognized Modifier (pos 11)
TRegExprW(comp):Urecognized Modifier (pos 11)
I'm currently using Total Commander Version 10.00 64bit
Re: RegEx search with omission
Which version of Total Commander are you using?kodepr wrote: 2022-03-13, 00:19 UTC That seems to produce an error:
TRegExprW(comp):Urecognized Modifier (pos 11)
Or perhaps you made a typing error?
Re: RegEx search with omission
Hello white,
My mistake: I was unaware of v10.00 release.
Error was in v9.51. Your solution works like a charm in v10.00.
Thank you!
My mistake: I was unaware of v10.00 release.
Error was in v9.51. Your solution works like a charm in v10.00.
Thank you!
I'm currently using Total Commander Version 10.00 64bit