Easy way to generate "System.InvalidOperationException: Nullable object must have a value."
using System; | |
public class Test | |
{ | |
public static void Main() | |
{ | |
int? nullableInt = null; | |
int nowInt = (int)nullableInt; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment