StringExtensions.ToInt64 method

Version 1.1.28
.NET Framework 4.8
Namespace Skybrud.Essentials.Strings.Extensions
Assembly Skybrud.Essentials.dll

ToInt64(string)

Extension method

Converts input to an instance of long . If the conversion fails, 0 will be returned instead.

public static long ToInt64(this string input)

Parameters

input String

The input string to be converted.

Returns

An instance of long .

ToInt64(string, long)

Extension method

Converts input to an instance of long . If the conversion fails, fallback will be returned instead.

public static long ToInt64(this string input, long fallback)

Parameters

input String

The input string to be converted.

fallback long

The fallback value that will be returned if the conversion fails.

Returns

An instance of long .