Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using (var context = new MyContext())
- {
- var userSettings = new UserSettings();
- userSettings.WindowHeight = 100;
- userSettings.WindowWidth = 400;
- userSettings.WindowX = 20;
- userSettings.WindowY = 25;
- var newObject= new MyClass();
- newObject.Settings = userSettings;
- context.Add(newObject);
- context.SaveChanges();
- }
Add Comment
Please, Sign In to add comment