Video Tutorial Library:

LINQ to SQL 101 :

LINQtoSQL101_04_02 - Hooking Entity Events using Partial Methods

Tags: VB , C# , Experienced , 2008 , LINQ
In this video we're going to pick up where we left off in the previous video by implementing two additional partial methods for our entities.  We'll use the OnCreated method to auto-populate the ID property of a new instances of an entity, which is particularly helpful when using uniqueidentifiers, or rather, GUIDs, as your primary key for your database tables as we do most often with all of our projects.  Then we'll look at the OnLoaded partial method to populate a new calculated property on our SalesOrderDetail entity at the moment when data is loaded from the database into our instances of our entity class.

Downloads:

Sign up today to access downloads.
LINQtoSQL101_04_02 - Hooking Entity Events using Partial Methods
Duration: 17 Minutes, 24 Seconds
Size: 21.15M
Recorded Using: Visual Studio 2008 (all versions)

Get Free Videos via Email

Sign up for our newsletter and receive links to free videos and more.

Subscribe

We don't rent/sell/or commit other evil deeds with your email address. See our Privacy Policy.