OpenAccess ORM version
|
2011.2 713
|
.NET version |
3.5
|
Visual Studio version |
2010
|
programming language |
C#
|
PROJECT DESCRIPTION
This project demonstrates how to customize the code generation in order to implement the INotifyPropertyChanging and INotifyPropertyChanged interfaces by defining a custom template for the Domain Model. This approach allows the user to "inject" any actions needed in the property setter.
The project includes both the custom template and a sample Domain Model defined using the template. It also provides an example for defining the event handlers.
For further information refer to the documentation at:
http://www.telerik.com/help/openaccess-orm/openaccess-tasks-model-tools-use-code-generation-templates-implement-inotifypropertychanged.html
Before running the project:
1) Run the DBScript.sql on an SQL Server 2008 installation
2) Configure the connection string HowToCustomizePropertySetterConnection in the following App.config file to point to the SQL database created by the provided script
3) Open the Domain Model, right click on it and select Show Model Settings. On the Advanced Settings tab, browse for Custom Template and select the CustomTemplate.tt file provided with the project.
4) Test the connectivity of the Domain Model