# Date of experiment recorded in MWorks data file?

**URL:** <https://mworks.discourse.group/t/date-of-experiment-recorded-in-mworks-data-file/438>\
**Category:** Support\
**Created:** [July 13, 2016, 6:16pm UTC](https://mworks.discourse.group/t/date-of-experiment-recorded-in-mworks-data-file/438 "2016-07-13T18:16:57Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![cstawarz](https://yyz1.discourse-cdn.com/flex031/user_avatar/mworks.discourse.group/cstawarz/32/3_2.png) [@cstawarz](https://mworks.discourse.group/u/cstawarz)\
**Post date:** [July 13, 2016, 6:16pm UTC](https://mworks.discourse.group/t/date-of-experiment-recorded-in-mworks-data-file/438/1 "2016-07-13T18:16:57Z")

</div>

Hi Chris,

Is the date that the data for an experiment ran in MWorks recorded anywhere in the associated mwk file? I’m looking for a robust method to detect the version of an experiment during data extraction. I know that you recently added the date to the automatic file name, but ideally my solution would be independent of the file name since the experimenter still has control over that and there is always the possibility that files are renamed.

Thanks,  
Seth

---

<div class="post-metadata">

**Author:** ![cstawarz](https://yyz1.discourse-cdn.com/flex031/user_avatar/mworks.discourse.group/cstawarz/32/3_2.png) [@cstawarz](https://mworks.discourse.group/u/cstawarz)\
**Post date:** [July 13, 2016, 6:31pm UTC](https://mworks.discourse.group/t/date-of-experiment-recorded-in-mworks-data-file/438/2 "2016-07-13T18:31:46Z")

</div>

Hi Seth,

As of MWorks 0.6, the MWorks version and current date/time are announced whenever an experiment starts running. In the console window, you’ll see something like this:

```
00:00:24: Running MWorks 0.7.dev
00:00:24: Current date/time is Wed Jul 13 14:21:17 EDT 2016

```

These messages are stored in the event file via the `#announceMessage` variable.

Additionally, the complete experiment XML is stored in the event file via the `#loadedExperiment` variable. If you really want to be sure what version of an experiment was used, you can extract the value of this variable and compare it to your saved XML files.

Cheers,  
Chris

---

<div class="post-metadata">

**Author:** ![cstawarz](https://yyz1.discourse-cdn.com/flex031/user_avatar/mworks.discourse.group/cstawarz/32/3_2.png) [@cstawarz](https://mworks.discourse.group/u/cstawarz)\
**Post date:** [July 13, 2016, 8:56pm UTC](https://mworks.discourse.group/t/date-of-experiment-recorded-in-mworks-data-file/438/3 "2016-07-13T20:56:51Z")

</div>

Hi Chris,

Thanks! I looks grabbing the #annouceMessages will do the trick. I was  
aware of the XML, but didn’t want to turn to that unless I had to.

Cheers,  
Seth

---

<div class="post-metadata">

**Author:** ![cstawarz](https://yyz1.discourse-cdn.com/flex031/user_avatar/mworks.discourse.group/cstawarz/32/3_2.png) [@cstawarz](https://mworks.discourse.group/u/cstawarz)\
**Post date:** [July 19, 2022, 10:01pm UTC](https://mworks.discourse.group/t/date-of-experiment-recorded-in-mworks-data-file/438/4 "2022-07-19T22:01:40Z")

</div>


