question

Anna Lisa Dierking avatar image
0 Likes"
Anna Lisa Dierking asked Jeff Nordgren edited

How to get a time stamp in day and time?

Hi,

I was wondering if there is an easy way to get a time stamp on an item/token in the same format as seen in the picture?

I know that I can the simulation time by using time() but I would like to get a real time stamp for my evalution to see when a process started and when the process finished. (eg. 23:30:15 So 3 Jul 2016)

FlexSim 16.1.1
model timeevaluationget model timetime stamp
time-stamp.png (17.4 KiB)
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

1 Answer

Matt Long avatar image
1 Like"
Matt Long answered Matt Long commented

The command you're looking for is:

getmodelunit(CURRENT_TIME_STR)

This will read the time and date format strings as defined in your model settings. By default the Date Time string will read:

8:00:00 AM Mon 22 Aug 2016

To adjust the format, open the Model Settings from the Edit menu, and change the Time Format and Date Format fields.


modelsettings.png (42.0 KiB)
· 1
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Anna Lisa Dierking avatar image Anna Lisa Dierking commented ·

Thank you. That's is exactly what I've been looking for.

0 Likes 0 ·