Text-field text to date-time tag property binding

Hi all,

Is there a way to specify the date-time string format of the text-field text when it is property bound to a date-time (memory) tag?

I have a memory tag whose data type is datetime. In the memory tag itself, I specify the FormatString to be

such that it shows a value like

Then, I created a text field whose text is property bound to the tag.

It shows text like this:

The millisecond precision is not shown in the text field. Somemore, the date-time display format is different.

Is there a way to specify the text-field text date-time display format when property bound to a date-time tag? If not, do we have to implement scripting to show the date-time text in the text-field text in format we want?

Thanks!

ian

when binding on to the text field use the “Date and Time–dateFormat” expression

like this

dateFormat({[System]Gateway/CurrentDateTime},"yyyy-MM-dd h:mm:ss.S")

Hi Chris,

That works! Thanks! :smiley: