I have an EF entity with string PK, an other entityes related to it
public class E1
{
public string PK {get;set;}
.....
}
During my proccess I assign a temporary PK to all my structure (E1 and related entities) awaiting the user to confirm the document.
If user confirm, I assign a definitelly PK and the database updates all ONCASCADE
My problem is when I'm trying to change the state of E1, it throws this exception
Property 'PK' is part of the info of object key, couldn't be modified
How can I do to avoid this Exception?