# Extract weekdays and month names from timestamp

**URL:** https://community.mp3tag.de/t/extract-weekdays-and-month-names-from-timestamp/13512
**Category:** Support
**Created:** [June 3, 2012, 7:28am UTC](https://community.mp3tag.de/t/extract-weekdays-and-month-names-from-timestamp/13512 "2012-06-03T07:28:59Z")
**Posts on this page:** 1
**Showing post:** 8

<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: [June 7, 2012, 10:40am UTC](https://community.mp3tag.de/t/extract-weekdays-and-month-names-from-timestamp/13512/8 "2012-06-07T10:40:22Z")

</div>

> [@LaurenBacall](#):
>
> I now know why Mp3Tag would crash when such a value is added to the loop. Thanks for the clarification, the help file could be a little clearer on this.

Hm, you can use a user defined variable to count how much iterations have been done so far.  
See Mp3tag Export Scripting Language functions: $put, $puts, $get.

Set variable in display mode (will be printed) ...  
$put(MyCounter,$add($get(MyCounter),1))  
... counts from $loop starting with 1 by 1 until $loopend.

Set variable in silent mode (will be not printed) ...  
$puts(MyCounter,$add($get(MyCounter),1))  
... counts from $loop starting with 1 by 1 until $loopend.

Use content of variable ...  
$ifgreater($get(MyCounter),20,'do nothing','do something')

But do not expect that the Mp3tag Export Scripting Language do behave like other programming languages!

Here is a test script to visualize the visibility of user defined variables within an export script.  
Note the quirky behaviour, when loops are embedded.  
[20120607.Test.Visibility.\_put.\_get.zip](https://community.mp3tag.de/uploads/default/original/2X/a/a89f1e5f7bee15e45bb327184604eae4f22f1417.zip) (689 Bytes)

DD.20120607.1438.CEST

[20120607.Test.Visibility.\_put.\_get.zip](https://community.mp3tag.de/uploads/default/original/2X/a/a89f1e5f7bee15e45bb327184604eae4f22f1417.zip) (689 Bytes)

---

_[View the full topic](https://community.mp3tag.de/t/extract-weekdays-and-month-names-from-timestamp/13512)._
