bph
09-11-2006, 10:47 PM
If I have a Card8 variable, set to some number of ticks like this:
m_LastChangedByEnviracom := m_TimeInfo.GetCurStamp() ;
and I want to see it as a string like "12:47:03" or even "124703", I don't understand what this means:
Time objects can be formatted to text in a number of flexible ways, because there are often needs to display only the time info or only the date info or to use certain well known standard formats. So each time objects has a format string, which uses the standard token replacement scheme of the MEng.String class. You can set a default format string on the time object, which contains replacement tokens, and when you format it, each token is replaced by the indicated field. The tokens are:
I am confused by "when you format it" and "standard token replacement scheme of the String class". What does "when you format it" actually mean? There is nothing about a format method on either the string page or the time page, that I can find.
Some examples would really help the documentation of these classes.
m_LastChangedByEnviracom := m_TimeInfo.GetCurStamp() ;
and I want to see it as a string like "12:47:03" or even "124703", I don't understand what this means:
Time objects can be formatted to text in a number of flexible ways, because there are often needs to display only the time info or only the date info or to use certain well known standard formats. So each time objects has a format string, which uses the standard token replacement scheme of the MEng.String class. You can set a default format string on the time object, which contains replacement tokens, and when you format it, each token is replaced by the indicated field. The tokens are:
I am confused by "when you format it" and "standard token replacement scheme of the String class". What does "when you format it" actually mean? There is nothing about a format method on either the string page or the time page, that I can find.
Some examples would really help the documentation of these classes.