Given this class
public partial class Default : Page
{
private IRepository repo;
...
}
I want to find and set the private repo field. Is that possible?
UPDATE
I tried using the GetFields(BindingFlags.NonPublic), it returns {System.Reflection.FieldInfo[0]}.
UPDATE II
I tried using the GetFields(BindingFlags.NonPublic | BindingFlags.Instance)
, it returns all the fields of the Page but not repo.