# App path in Export target

**URL:** https://community.mp3tag.de/t/app-path-in-export-target/16124
**Category:** Support
**Created:** [September 10, 2014, 11:48pm UTC](https://community.mp3tag.de/t/app-path-in-export-target/16124 "2014-09-10T23:48:41Z")
**Posts on this page:** 10
**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: [September 10, 2014, 11:48pm UTC](https://community.mp3tag.de/t/app-path-in-export-target/16124/1 "2014-09-10T23:48:41Z")

</div>

How can I get "Export file name" to reference a path relative to Mp3tag.exe? e.g.

$filename($getenv(MP3TAGEXEPATH)..\myfile.txt,ANSI)

-\>

S:\TLIB importing! Curtains\mp3tag..\myfile.txt

---

<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: [September 11, 2014, 4:53am UTC](https://community.mp3tag.de/t/app-path-in-export-target/16124/2 "2014-09-11T04:53:55Z")

</div>

> [@chrisjj](#):
>
> How can I get "Export file name" to reference a path relative to Mp3tag.exe? ...

**$getEnv('MP3TAGAPP')**

See also ...  
[Filename function in export configurations](https://community.mp3tag.de/t/15820/2)  
[Not showing the Year, Comment, Copyright and Web address details.](https://community.mp3tag.de/t/14343/7)  
[Test.getEnv.mte](https://community.mp3tag.de/uploads/default/original/2X/1/1852a2cc96f509de6b8d7a1352265a666299afd5.mte) (1.85 KB)  
This should be also possible:  
Set by yourself a dedicated environment variable before invoking Mp3tag.exe,  
then get the value using the function $getEnv().

DD.20140911.0917.CEST

[Test.getEnv.mte](https://community.mp3tag.de/uploads/default/original/2X/1/1852a2cc96f509de6b8d7a1352265a666299afd5.mte) (1.85 KB)

---

<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 11, 2014, 9:54am UTC](https://community.mp3tag.de/t/app-path-in-export-target/16124/3 "2014-09-11T09:54:23Z")

</div>

> [@DetlevD](#):
>
> **$getEnv('MP3TAGAPP')**

Thanks. I was sure I recall mention, but then found nothing in the docs.  
[https://www.google.co.uk/search?q=site%3Ahe...ag.de+MP3TAGAPP](https://www.google.co.uk/search?q=site%3Ahelp.mp3tag.de+MP3TAGAPP)

> [@DetlevD](#):
>
> **$getEnv('MP3TAGAPP')**

Why the single quotes?

> [@DetlevD](#):
>
> This should be also possible:  
> Set by yourself a dedicated environment variable before invoking Mp3tag.exe,  
> then get the value using the function $getEnv().

Ah! Could be a great way of parameterising exports and esp. actions in my batchfile-launched Mp3tag.exe commands. Have you tried that?

---

<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: [September 11, 2014, 2:27pm UTC](https://community.mp3tag.de/t/app-path-in-export-target/16124/4 "2014-09-11T14:27:04Z")

</div>

> [@chrisjj](#):
>
> Why the single quotes?

Hmm, although the string MP3TAGAPP could be or is the name of a predefined symbol or any Objectname, I treat the parameter of the $getEnv() function as of datatype string.  
I use it as the textual name for a placeholder, like it is used within the DOS cmd shell.  
My syntax colorizer likes it too.  
The parameter of the $getEnv function is scriptable, for example ...

**$getEnv($upper($replace('processor?architecture','?','\_')))**

> [@chrisjj](#):
>
> Ah! Could be a great way of parameterising exports and esp. actions in my batchfile-launched Mp3tag.exe commands. Have you tried that?

Not yet, but it could be done by invoking a batch file, which at first creates the environment for the subsequent call to the Mp3tag application.

DD.20140911.1827.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 11, 2014, 3:28pm UTC](https://community.mp3tag.de/t/app-path-in-export-target/16124/5 "2014-09-11T15:28:07Z")

</div>

> [@DetlevD](#):
>
> I treat the parameter of the $getEnv() function as of datatype string.

I guess the value has not yet included single quote 🙂

> [@DetlevD](#):
>
> Not yet, but it could be done by invoking a batch file, which at first creates the environment for the subsequent call to the Mp3tag application.

Thanks.

---

<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: [September 11, 2014, 4:39pm UTC](https://community.mp3tag.de/t/app-path-in-export-target/16124/6 "2014-09-11T16:39:23Z")

</div>

> [@chrisjj](#):
>
> Ah! Could be a great way of parameterising exports and esp. actions in my batchfile-launched Mp3tag.exe commands. ...

One can also think of quite specific uses.  
With Mp3tag via export do create a cmd file, which in turn, when executed, opens a new Mp3tag session, respectively replaces the current session, with a new preset environment.

DD.20140911.2039.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 11, 2014, 4:42pm UTC](https://community.mp3tag.de/t/app-path-in-export-target/16124/7 "2014-09-11T16:42:03Z")

</div>

I use Mp3tag as a semi-manual batch commend in otherwise automatic tag processing, so I would love to know how to get app launch to automatically run an action and then quit.

---

<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: [September 12, 2014, 2:44pm UTC](https://community.mp3tag.de/t/app-path-in-export-target/16124/8 "2014-09-12T14:44:08Z")

</div>

One could imagine:  
A command line parameter for Mp3tag.exe, which receives the filepathname of a simple text file (filetype .mtb .mtbatch ???), in which each "Action" line contains the name of an action group (the filepathname), so that Mp3tag can execute the named action group.  
Comment lines should be allowed too.  
If "Comment" lines or "Message" lines could be displayed in a simple message window, this would be fine too.  
This batch run message window should have a button to exit the batch immediately, if necessary.  
Such a batch process would run on the full responsibility of the user, because there is no turning back or "undo" of any change applied while batch time.

DD.20140912.1844.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 12, 2014, 3:19pm UTC](https://community.mp3tag.de/t/app-path-in-export-target/16124/9 "2014-09-12T15:19:04Z")

</div>

One sure could.

That would be great.

But IIRC Florian has said he will not support commandline scripting of actions.

> [@DetlevD](#):
>
> This batch run message window should have a button to exit the batch immediately, if necessary.

I'd prefer no GIU. Just console.

---

<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 9, 2026, 12:25pm UTC](https://community.mp3tag.de/t/app-path-in-export-target/16124/10 "2026-02-09T12:25:15Z")

</div>


