TryParse

Length.TryParse method

Tries to parse a specified string as a Length value, including its numeric value and unit name

public static bool TryParse(string input, out Length result)
Parameter Type Description
input String Input string, that should be parsed
result Length& Output parameter, that contains a result of parsing. If parsing is unsuccessful, contains a default Length value — a unitless zero.

Return Value

True if parsing is successful, false if unsuccessful

See Also