I have multiple files like this:
abcdef_200.46.log
For all of these files, I want to rename to :
abcdef_200.46_.log
I used the Search and Replace, with this pattern:
46.log/46_.log
(I don't want to rely on the 46 alone, rather 46 before the .log extension)
Search and Replace does not change the 46 to 46_ . I looked around on topics on this, and I have
Configuration/Search and Replace/Replace / Exclude extensions unchecked. It does the same
if it is checked.
Is the extra '.' between 200 and 46 messing things up?
thanks,
John
Renaming does not seem to work..
-
highend
- Posts: 15004
- Joined: 06 Feb 2011 00:33
- Location: Win Server 2022 @100%
Re: Renaming does not seem to work..
No time to check this but if you just want the job done, you could use
RegExp Rename... instead
RegExp Rename... instead
Code: Select all
46.log$ > 46_.logOne of my scripts helped you out? Please donate via Paypal
-
admin
- Site Admin
- Posts: 66719
- Joined: 22 May 2004 16:48
- Location: Win8.1, Win10, Win11, all @100%
- Contact:
Re: Renaming does not seem to work..
You should append the /e switch (= include extensions), else the sequence "46.log" is looked for only in the base name (and not found).
Code: Select all
46.log/46_.log /eFAQ | XY News RSS | XY X
-
john3774
- Posts: 28
- Joined: 27 Aug 2010 16:54
Re: Renaming does not seem to work..
Including the /e does not seem to work. I am using Search and Replace.
For this example
trying to rename test2.bmp to: test_2.bmp
with this command: 2.bmp/_2.bmp /e
I get a dialog box with the following error:
This is not a valid filename:
_2.bmp /e
The following characters are not allowed: \ / : * ? " < > |
For this example
trying to rename test2.bmp to: test_2.bmp
with this command: 2.bmp/_2.bmp /e
I get a dialog box with the following error:
This is not a valid filename:
_2.bmp /e
The following characters are not allowed: \ / : * ? " < > |
-
admin
- Site Admin
- Posts: 66719
- Joined: 22 May 2004 16:48
- Location: Win8.1, Win10, Win11, all @100%
- Contact:
-
john3774
- Posts: 28
- Joined: 27 Aug 2010 16:54
Re: Renaming does not seem to work..
Version 16.30.
thanks,
John
thanks,
John
-
admin
- Site Admin
- Posts: 66719
- Joined: 22 May 2004 16:48
- Location: Win8.1, Win10, Win11, all @100%
- Contact:
Re: Renaming does not seem to work..
Too old. The /e switch was added in v17.20.0102. 
FAQ | XY News RSS | XY X
-
john3774
- Posts: 28
- Joined: 27 Aug 2010 16:54
Re: Renaming does not seem to work..
I'm trying to add characters to the end of a filename with .BMP extension. Unlike previous tries, where the Search and Replace option on :
xyz.bmp/xyz2018.bmp/e would work with the e flag,
If I don't have characters in front of the '.bmp', this generates an error.
So this:
.bmp/2018.bmp/e generates an error. (This is not a valid filename, special characters not allowed).
I have Version 18.00.
Thanks, John
xyz.bmp/xyz2018.bmp/e would work with the e flag,
If I don't have characters in front of the '.bmp', this generates an error.
So this:
.bmp/2018.bmp/e generates an error. (This is not a valid filename, special characters not allowed).
I have Version 18.00.
Thanks, John
-
RalphM
- Posts: 2122
- Joined: 27 Jan 2005 23:38
- Location: Cairns, Australia
Re: Renaming does not seem to work..
Have you tried this with a space before the /e flag?john3774 wrote:.bmp/2018.bmp/e
Another option would be to forget about the extension and just do a Batch Rename with *2018 but this would rename any selected file not just BMP's.
Ralph 
(OS: W11 25H2 Home x64 - XY: Current x64 beta - Office 2024 64-bit - Display: 1920x1080 @ 125%)
(OS: W11 25H2 Home x64 - XY: Current x64 beta - Office 2024 64-bit - Display: 1920x1080 @ 125%)
XYplorer Beta Club