ArcObjects Library Reference (System)  

ITime.SetFromTimeStringCustom Method

Writes the time from a string, based on the given custom time string formats, and locale properties.

[Visual Basic .NET]
Public Sub SetFromTimeStringCustom ( _
    ByVal timeStringFormat As String, _
    ByVal LocaleID As Integer, _
    ByVal amSymbol As String, _
    ByVal pmSymbol As String, _
    ByVal timeString As String _
)
[C#]
public void SetFromTimeStringCustom (
    string timeStringFormat,
    int LocaleID,
    string amSymbol,
    string pmSymbol,
    string timeString
);
[C++]
HRESULT SetFromTimeStringCustom(
  BSTR timeStringFormat,
  long LocaleID,
  BSTR amSymbol,
  BSTR pmSymbol,
  BSTR timeString
);
[C++]

Parameters

timeStringFormat [in]   timeStringFormat is a parameter of type BSTR LocaleID [in]   LocaleID is a parameter of type long amSymbol [in]   amSymbol is a parameter of type BSTR pmSymbol [in]   pmSymbol is a parameter of type BSTR timeString [in]   timeString is a parameter of type BSTR

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Description

The passed time string is assumed to be in a format specified by the time format string, date format string, and using the AM/PM designators.  The time format string uses the following symbols:

 

h = hour (12 hour clock)

H = hour (24 hour clock)

m = minute

s = second

t = am/pm designator

hh,mm,ss indicate that there is a leading zero for values less than 10

h,m,s indicate that there is no leading zero

Note that the am/pm designator should not be present when the time is measured using a 24-hour clock

the AM/PM designators will only be used if the time string contains the "t" value

 

The date format string uses the following symbols:

M = month of the year

d = day of the month

y = year

MM and dd indicate that there is a leading zero when the month/day is less than 10

M and d indicate that there is no leading zero

yy indicates a 2 digit year

yyyy indicates a 4 digit year

 

 

 

See Also

ITime Interface