Snippet: if not TryParse

property value
IDE VS Code
Language C#
Title if not TryParse
Shortcut ifxtp
Description if statement with condition whether TryParse method returns false.

Placeholders

Identifier Tooltip Default Value
_type The type of the value to parse T
result The result x
value The value to parse value

Code

T x;
if (!T.TryParse(value, out x)) {
	
}