I have this code:
using DC = MV6DataContext;
using MV6; // Business Logic Layer
// ...
public DC.MV6DataContext dc = new DC.MV6DataContext(ConnectionString)
Got it.
Rather than creating a class that inherits from the DataContext's class, I extend the DC class itself with a partial class in the Business Logic layer. From there I can add whatever constructors and methods I wish.
In this case, it is neccessary to copy the code from the existing (auto-generated) constructor:
public IP(string address) {
Address = address;
Domain = "";
Notes = "";
FirstAccess = DateTime.Now;
LastAccess = DateTime.Now;
this._Sessions = new EntitySet(new Action(this.attach_Sessions), new Action(this.detach_Sessions));
OnCreated(); }
Not sure what's in that OnCreated handler, but it seems to be doing the work that boned me earlier. Works fine now :)