# \[X\] $filename() change failure in Action Export

**URL:** https://community.mp3tag.de/t/x-filename-change-failure-in-action-export/8754
**Category:** No Bugs
**Created:** [August 10, 2009, 9:57pm UTC](https://community.mp3tag.de/t/x-filename-change-failure-in-action-export/8754 "2009-08-10T21:57:32Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![chrisjj](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/c/a698b9/32.png) [@chrisjj](https://community.mp3tag.de/u/chrisjj)
#### Post date: [August 10, 2009, 9:57pm UTC](https://community.mp3tag.de/t/x-filename-change-failure-in-action-export/8754/1 "2009-08-10T21:57:32Z")

</div>

1 In an Action, include an Export using $filename(xxx)  
2 In the .mte file, change xxx to yyy  
3 Run the Action

Expected: Export output file is yyy  
Observed: Export output file is xxx!

It seems Mp3tag is using the $filename() value current at the time the Export dialog box is closed, failing to read it at the time the .mte is actually executed upon the Export.

---

<div class="post-metadata">

### Author: ![Florian](https://community.mp3tag.de/user_avatar/community.mp3tag.de/florian/32/5759_2.png) [@Florian](https://community.mp3tag.de/u/Florian)
#### Post date: [August 12, 2009, 8:22am UTC](https://community.mp3tag.de/t/x-filename-change-failure-in-action-export/8754/2 "2009-08-12T08:22:45Z")

</div>

> [@chrisjj](#):
>
> It seems Mp3tag is using the $filename() value current at the time the Export dialog box is closed, failing to read it at the time the .mte is actually executed upon the Export.

This is the expected behaviour to respect changes made by the user to the pre-filled output filename (which would be discarded if the filename is build at the time the export is executed).

---

<div class="post-metadata">

### Author: ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)
#### Post date: [August 12, 2009, 8:46am UTC](https://community.mp3tag.de/t/x-filename-change-failure-in-action-export/8754/3 "2009-08-12T08:46:28Z")

</div>

> [@chrisjj](#):
>
> ... It seems Mp3tag is using the $filename() value current at the time the Export dialog box is closed, failing to read it at the time the .mte is actually executed upon the Export.

Yes, after a change in the export script you have to close and re-open the export dialog to refresh resp. to clear the quirky situation.

DD.20090812.1245.CEST

---

<div class="post-metadata">

### Author: ![chrisjj](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/c/a698b9/32.png) [@chrisjj](https://community.mp3tag.de/u/chrisjj)
#### Post date: [September 13, 2009, 10:58pm UTC](https://community.mp3tag.de/t/x-filename-change-failure-in-action-export/8754/4 "2009-09-13T22:58:03Z")

</div>

> This is the expected behaviour to respect changes made by the user to the  
> pre-filled output filename (which would be discarded if the filename is build  
> at the time the export is executed).

OK... but then I have to say I think it could do a better job. In this case the script's change is blocked even though there is no user's change. This can lead to error and is unexpected because of the hidden change in significance of the script filename.

I suggest the best solution would be to have no blocking - i.e. if/when there's a script change, it goes to the output filename. And when/if there is a user change, it too goes to the output filename.

But Iaccept that probably few use this, and it should be low priority.

---

<div class="post-metadata">

### Author: ![Florian](https://community.mp3tag.de/user_avatar/community.mp3tag.de/florian/32/5759_2.png) [@Florian](https://community.mp3tag.de/u/Florian)
#### Post date: [December 28, 2018, 2:26pm UTC](https://community.mp3tag.de/t/x-filename-change-failure-in-action-export/8754/5 "2018-12-28T14:26:25Z")

</div>

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