Tried that bu it doens't seem to work - I'm getting similar errors as when I used writexml readxml approach to refresh entity content.
Please confirm that followin should give exactly the same result:
(1)
MyEntity entity = GetEntity(1);
//Some operations, saving entity with id 1 using another reference to it.
entity = GetEntity(1); // entity is up to date !!!
MyEntity entity = GetEntity(1);
//Some operations, saving entity with id 1 using another reference to it.
entity.RefreshEntity(); // entity is up to date !!!
MyEntity GetEntity(int id)
{
MyEntity entity = new MyEntity(id);
using (DataAccessAdapter adapter = new DataAccessAdapter())
{
adapter.FetchEntity(entity, COMPLEX PREFETCH PATH HERE);
}
return entity;
}
public static void RefreshEntity(this MyEntity entity)
{
using (DataAccessAdapter adapter = new DataAccessAdapter())
{
adapter.FetchEntity(entity, COMPLEX PREFETCH PATH HERE);
}
}
BTW: I updated to 2.6.09.0116 (libraries only, not LLBLGen app)