Skip to main content
Known Participant
Nov 3, 2021 9:58 PM UTC
Question

Renaming with Redex

Hello together,

I have one Field with semicolon seperated

 

Behandlungen 45 Sek 1:1; Treatments 45 Sec 1:1;

 

And I want to have

 

Behandlungen 45 Sek 1:1

 

My regex is ;.*

 

But it doesn't work

 

Can help me. Thanks

This topic is closed to new replies. Start a new post to keep the conversation going.

7 replies

Stephen Marsh
Community Expert
Community Expert
Nov 3, 2021 11:03 PM UTC

One method:

 

Find:

(^.+)(; .*)

 

Replace:

$1

 

Translate
gregreser
Legend
Nov 4, 2021 1:35 AM UTC

Your original method worked for me. The method @Stephen Marsh suggested also worked.

 

The only difference is that in your screenshot, the current filename is Behandlungen 45 Sek 1:1; Treatments 45 Sec 1:1;.mp4  Is that really the original filename or is it an aboration of the batch rename tool? I wouldn't think it's possible to have that filename in Windows.

 

Translate
Stephen Marsh
Community Expert
Community Expert
Nov 4, 2021 2:30 AM UTC

@gregreser 

 

A colon is indeed an illegal filename character, so 1:1 would not work, the screenshot shows 1-1...

 

Translate