So I know all of you that actually read my initial post are thinking, "Great... Now I have detached objects. I spent an hour making the modifications you told me to, but I still can't do anything with them!" So take a deep breath and lets cover how to save your detached Linq 2 SQL entities.
First, Lets take advantage of those partial L2S Entities
Some of you know what partial classes are, some of you may not. So lets begin there.
"A partial class, or partial type, is a feature of some object oriented computer programming languages in which the declaration of a class may be split across multiple source-code files, or multiple places within a single file." You can read more here: http://en.wikipedia.org/wiki/Partial_Classes
.NET requires the class be the same name and be in the same namespace. So lets go back to our User example.
User
int UserID
EntityRef<UserType>
Your definition for this class likely looks similar to:
[Table(Name="dbo.USER")]
[DataContract()]
public partial class USER : INotifyPropertyChanging, INotifyPropertyChanged {.......
So my suggestion create a *.CS file named something along the lines of "EntityExtensions.cs"
I know we have a class already taking advantage of this if you are following from yesterday's post, however, lets re-iterate what we have again.
{