private string? typeOfContract
{
get { return (string?)ViewState[\"typeOfContract\"]; }
set { ViewState[\"typeOfContract\"] = value; }
}
Later
string cannot be the parameter to Nullable because string is not a value type. String is a reference type.
string s = null;
is a very valid statement and there is not need to make it nullable.
private string typeOfContract
{
get { return ViewState["typeOfContract"] as string; }
set { ViewState["typeOfContract"] = value; }
}
should work because of the as keyword.