|
TimeToString(Int32, Double) Method
|
Converts the
Time value into a textual representation of years, days, hours,
minutes and seconds with the specified number of fractional digits.
Namespace: GSF.UnitsAssembly: GSF.Core (in GSF.Core.dll) Version: 2.4.260-beta+0f4e919571e6ec7e8e07a8e325416284b7e38fa3
Syntaxpublic string ToString(
int secondPrecision,
double minimumSubSecondResolution = 0.001
)
Public Function ToString (
secondPrecision As Integer,
Optional minimumSubSecondResolution As Double = 0.001
) As String
public:
String^ ToString(
int secondPrecision,
double minimumSubSecondResolution = 0.001
)
member ToString :
secondPrecision : int *
?minimumSubSecondResolution : float
(* Defaults:
let _minimumSubSecondResolution = defaultArg minimumSubSecondResolution 0.001
*)
-> string function ToString(secondPrecision, minimumSubSecondResolution);
View SourceParameters
- secondPrecision Int32
- Number of fractional digits to display for seconds.
- minimumSubSecondResolution Double (Optional)
-
Minimum sub-second resolution to display. Defaults to Milli.
Return Value
String
The string representation of the value of this instance, consisting of the number of
years, days, hours, minutes and seconds represented by this value.
Exceptions| Exception | Condition |
|---|
| ArgumentOutOfRangeException | minimumSubSecondResolution is not less than or equal to Milli or
minimumSubSecondResolution is not defined in Factors array.
|
RemarksSet second precision to -1 to suppress seconds display.
See Also