Hi all,
I have a project c# in FW4.0 that uses EF5.0 (DB First).
In many lines the code is used:
if (h.GetType (). Name == "Customer")
where h (Customer) is the object of my context .
Now I find myself errors because by analyzing h I find myself
System.Data.Entity.DynamicProxies.Customer_232B1622 .... etc
I have read that it is possible to disable the proxy by adding:
this.Configuration.ProxyCreationEnabled = false;
However, I get errors, the POCO classes are returned empty.
And then every time I regenerate the edmx I have to remember to go and put the line above in the .tt file.
Does anyone know how to resolve?
I would like not to touch the code because there are so many lines.
Thanks
I have a project c# in FW4.0 that uses EF5.0 (DB First).
In many lines the code is used:
if (h.GetType (). Name == "Customer")
where h (Customer) is the object of my context .
Now I find myself errors because by analyzing h I find myself
System.Data.Entity.DynamicProxies.Customer_232B1622 .... etc
I have read that it is possible to disable the proxy by adding:
this.Configuration.ProxyCreationEnabled = false;
However, I get errors, the POCO classes are returned empty.
And then every time I regenerate the edmx I have to remember to go and put the line above in the .tt file.
Does anyone know how to resolve?
I would like not to touch the code because there are so many lines.
Thanks