|
|
|
SftMaskCalendar.FormatTimeV Method |
Converts a time into a displayable string.
Syntax
VB.NET |
object.FormatTimeV(ByVal Dt As Date, ByRef Text As Object) |
||
VB |
object.FormatTimeV(ByVal Dt As Date, Text As Variant) |
||
C#.NET |
void object.FormatTimeV(System.DateTime Dt, ref object Text); |
||
VC++ |
HRESULT object->FormatTimeV(DATE Dt, const _variant_t&* Text); |
||
C |
HRESULT object->raw_FormatTimeV(DATE Dt, VARIANT* Text); |
||
Delphi |
procedure object.FormatTimeV(Dt : TDateTime, var Text : OleVariant); |
object
A SftMaskCalendar object.
Dt
The time to be converted to a string. The converted time is returned in the Text argument.
Text
Defines the desired formatting for the specified Time Dt and returns the converted time as a string. If an empty string is specified, the time is formatted using the default user locale.
Comments
The FormatTimeV method converts a time into a displayable string.
The FormatTimeV method uses the Windows GetTimeFormat API to format the specified time Dt.
Text can be defined as an empty string or can consist of one or more of the following items:
Text |
Description |
h |
Hours without leading zero for single-digit hours - 12-hour clock |
hh |
Hours with leading zero for single-digit hours - 12-hour clock |
H |
Hours without leading zero for single-digit hours - 24-hour clock |
HH |
Hours with leading zero for single-digit hours - 24-hour clock |
m |
Minutes without leading zero for single-digit minutes |
mm |
Minutes with leading zero for single-digit minutes |
s |
Seconds without leading zero for single-digit seconds |
ss |
Seconds with leading zero for single-digit seconds |
t |
One character time-marker string, such as A or P. |
tt |
Full length, multicharacter time-marker string, such as AM or PM |
Literal characters must be enclosed by single quotes.
Text = "hh':'mm':'ss tt"
To specify a literal single quote, use two quotes.
FormatTimeV is used for languages such as VBScript, which are limited by requiring Variant arguments and do not support strongly typed arguments for return values. For more information please see Using SftMask/OCX with Internet Explorer.