You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
hi,
I have a Person class
Person is a parent of an Address, the relation is one to many (parent has many Addresses)
like that (taken from the constructor of Person):
Addresses = new ChangeTrackingCollection
();
I need when I add Address to person like that:
addresses .Add(new Address())
the properties Person and PersonID in Address getting values according to the Person
how can I do this?
do I need to used with Parent field from ChangeTrackingCollection class? If so how?
Thanks in advance
The text was updated successfully, but these errors were encountered:
@orit1, Thanks for the question. You don't have to populate these fields on the client. They will be populated by EF on the server when the entity is saved.
Another important thing -
If I work connect, the fields get values on the server like you said
But if I'm working dissconnect also on the server it doesn't happen
Is there a way to work dissconnect and that the fields fill up?
hi,
();I have a Person class
Person is a parent of an Address, the relation is one to many (parent has many Addresses)
like that (taken from the constructor of Person):
Addresses = new ChangeTrackingCollection
I need when I add Address to person like that:
addresses .Add(new Address())
the properties Person and PersonID in Address getting values according to the Person
how can I do this?
do I need to used with Parent field from ChangeTrackingCollection class? If so how?
Thanks in advance
The text was updated successfully, but these errors were encountered: