# Format String Year

**URL:** https://community.mp3tag.de/t/format-string-year/61838
**Category:** Allgemein
**Created:** [August 16, 2023, 8:00pm UTC](https://community.mp3tag.de/t/format-string-year/61838 "2023-08-16T20:00:23Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![cmsmith21](https://community.mp3tag.de/user_avatar/community.mp3tag.de/cmsmith21/32/7386_2.png) [@cmsmith21](https://community.mp3tag.de/u/cmsmith21)
#### Post date: [August 16, 2023, 8:00pm UTC](https://community.mp3tag.de/t/format-string-year/61838/1 "2023-08-16T20:00:23Z")

</div>

Ich würde gerne eine Aktion anlegen, die das aktuelle Datum selbstständig in das Feld "YEAR" in folgenden Format schreibt: YYYY-MM-DD. Vielen Dank schonmal für eure Hilfe.

---

<div class="post-metadata">

### Author: ![ohrenkino](https://community.mp3tag.de/user_avatar/community.mp3tag.de/ohrenkino/32/4843_2.png) [@ohrenkino](https://community.mp3tag.de/u/ohrenkino)
#### Post date: [August 16, 2023, 8:16pm UTC](https://community.mp3tag.de/t/format-string-year/61838/2 "2023-08-16T20:16:40Z")

</div>

Es gibt eine Variable %\_datetime%, die das vollständige Datum der aktuellen Systemzeit ausgibt, also z.B. 16.08.2023 22:13:23  
Das Format der Systemzeit ist abhängig von den Systemeinstellungen.  
Ggf. musst du da noch was umstellen und abschneiden.

Ich möchte in diesem Zusammenhang darauf hinweisen, dass YEAR gem. ID3-Norm nur 4 Ziffern lang ist. Längere Angaben führen mindestens zu einem ungültigen Format, ggf. zu Problemen im Abspieler.

Für das längere Datum würde sich statt YEAR das Feld RELEASETIME anbieten.

Hier ist ein Thread mit einem Beispielausdruck, wie man Ziffern umstellen kann:

> [@ID-Tag mit komplettem Datum](https://community.mp3tag.de/t/id-tag-mit-komplettem-datum/10821/8):
>
> Damit müsste es gehen: $regexp("STRING VON DANO",(.\*)-(.\*)-(.\*),$3.$2.$1) "STRING VON DANO" bitte mit dem Formatstring von Dano ersetzen, der funktioniert. mfG gnor

---

<div class="post-metadata">

### Author: ![cmsmith21](https://community.mp3tag.de/user_avatar/community.mp3tag.de/cmsmith21/32/7386_2.png) [@cmsmith21](https://community.mp3tag.de/u/cmsmith21)
#### Post date: [August 16, 2023, 11:04pm UTC](https://community.mp3tag.de/t/format-string-year/61838/3 "2023-08-16T23:04:34Z")

</div>

Danke für deine Vorschläge, aber das war nicht das was ich wollte. Ich konnte es jetzt lösen, in dem ich das Datumsformat in den Systemeinstellungen (Win11) geändert habe. Von 17.08.2023 in 2023-08-17. Mit dem Befehl Tagfeld formatieren "YEAR": %\_date% in Aktionen erreiche ich dann in Zukunft, was ich wollte.

---

<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: [September 15, 2023, 11:04pm UTC](https://community.mp3tag.de/t/format-string-year/61838/4 "2023-09-15T23:04:53Z")

</div>

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