# "Path not found" when changing \_FILENAME with special chars under Wine

**URL:** https://community.mp3tag.de/t/path-not-found-when-changing-filename-with-special-chars-under-wine/54075
**Category:** No Bugs
**Created:** [August 14, 2021, 2:52pm UTC](https://community.mp3tag.de/t/path-not-found-when-changing-filename-with-special-chars-under-wine/54075 "2021-08-14T14:52:37Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Jonny007-MKD](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/j/ebca7d/32.png) [@Jonny007-MKD](https://community.mp3tag.de/u/Jonny007-MKD)
#### Post date: [August 14, 2021, 2:52pm UTC](https://community.mp3tag.de/t/path-not-found-when-changing-filename-with-special-chars-under-wine/54075/1 "2021-08-14T14:52:37Z")

</div>

Hi there,

I'm using Mp3tag for quite a while but just discovered that Actions are exactly what I need 😊 I'm running Mp3tag in Wine as there is no such good and usable tool natively on Linux. I created some Actions for my usual workflows and discovered a bug (I think).

I am using the "Format value" action for \_FILENAME and this format string: `"%artist%\%album%\$num(%track%,2) - %title%.%_extension%"`

> File  
> "Z:\home\user\Music\ToDo\Artist with Questionmark\_\AlbumX\01 - Title.mp3"  
> cannot be renamed to  
> "Z:\home\user\Music\Artist with Questionmark\AlbumX\01 - Title.mp3"
> 
> Path not found

The artist is "Artist with Questionmark?" which is of course not a valid path for Windows software. The "Tag -\> Filename" feature which I used to use did never have a problem with this, though (even under Wine). It just removes the invalid characters from the path. So my guess is that at this point the paths aren't sanitized correctly/completely.

---

<div class="post-metadata">

### Author: ![LyricsLover](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/l/c6cbf5/32.png) [@LyricsLover](https://community.mp3tag.de/u/LyricsLover)
#### Post date: [August 14, 2021, 5:07pm UTC](https://community.mp3tag.de/t/path-not-found-when-changing-filename-with-special-chars-under-wine/54075/2 "2021-08-14T17:07:51Z")

</div>

You could try it with [$validate](https://docs.mp3tag.de/scripting/#string-functions).

Something like:  
`$validate(%artist%\%album%\$num(%track%,2) - %title%.%_extension%,-)`

I'm not sure, if this works on Linux/Wine too. It should replace all the non valid characters like ? or \* with a -. Feel free to change the replacement character.

---

<div class="post-metadata">

### Author: ![system](https://community.mp3tag.de/uploads/default/original/2X/c/ce7035d426cb755a7916793326d23b465222a407.png) [@system](https://community.mp3tag.de/u/system)
#### Post date: [February 11, 2022, 8:12am UTC](https://community.mp3tag.de/t/path-not-found-when-changing-filename-with-special-chars-under-wine/54075/3 "2022-02-11T08:12:25Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
