I got StackOverflowException in my code
public int Movie_ID
{
set
{
if (value == 0)
{
throw new Exception("value cannot be empty");
}
Movie_ID = value;
}
get
{
return Movie_ID;
}
}
Exception of type 'System.StackOverflowException' was thrown."}
return Movie_ID;callsMovie_ID;which calls (via property)return Movie_ID;etc.