View previous topic :: View next topic |
Author |
Message |
Newton
Joined: 23 Jan 2010 Posts: 2
|
Posted: Sat Jan 23, 2010 5:26 pm Post subject: Removing the first '-' only |
|
|
ok, so my file name looks either like this
- file - name.mp3
or
-file - name.mp3
what i want it to look like is
file - name.mp3
i.e. only remove the first hyphen and/or space.
what i have is \-. but that removes ALL hyphens, which i don't want... any ideas? |
|
Back to top |
|
 |
admin Site Admin
Joined: 09 Mar 2007 Posts: 448 Location: Canada
|
Posted: Sat Jan 23, 2010 8:04 pm Post subject: |
|
|
Hi,
You can use the counter extension I added for regular expressions. P Paste the following into the search column (without the single quotes):
'(?1)\-'
This will replace the first dash character with whatever you put in the replace column.
Peter. |
|
Back to top |
|
 |
tbabyren
Joined: 18 Aug 2010 Posts: 2
|
Posted: Wed Aug 18, 2010 12:17 pm Post subject: |
|
|
I tried that and it still wants to remove the second instance of the "-". Am I missing something? It shows in the preview that its going to do what I want but when I run it it doesn't. What if I just want to remove the "-". How do I just delete and not replace? |
|
Back to top |
|
 |
admin Site Admin
Joined: 09 Mar 2007 Posts: 448 Location: Canada
|
Posted: Wed Aug 18, 2010 2:30 pm Post subject: |
|
|
Hi,
Using the (?1)\-' expression in the search field should work (without inlcuding the single quotes). If it works for the preview panel it has to work for the preview page.
To delete the '-', just leave the replace field empty.
Would you please send me your 'Config' file so I can have a look at it - the file can be found in the Application Data\PFrank folder
e.g. for XP:
C:\Documents and Settings\peter\Application Data\PFrank\Config
The location is similar for Vista/WIndows7
Peter.
Last edited by admin on Wed Aug 18, 2010 3:44 pm; edited 1 time in total |
|
Back to top |
|
 |
tbabyren
Joined: 18 Aug 2010 Posts: 2
|
Posted: Wed Aug 18, 2010 2:59 pm Post subject: |
|
|
I also don't want instances of only 1 "-" being changed but I got it to work by selecting the files I didn't want changed and removing them from the list but is there a faster way to exclude files with only 1 "-" I still have another 30,000 songs to go through. Much appreciated on response time!! |
|
Back to top |
|
 |
admin Site Admin
Joined: 09 Mar 2007 Posts: 448 Location: Canada
|
Posted: Wed Aug 18, 2010 3:46 pm Post subject: |
|
|
OK - you wouldl also need to use the name filter to pre-filter names to eliminate names that only have 1 dash.
Set the name filter to:
*-*-*
And then scan.
Peter. |
|
Back to top |
|
 |
|