I'm getting an error "object reference not set to an instance of an object" - C#