dr11
dr11

Reputation: 5726

Generate model classes from Database for Linq to SQL

I have VS Database project with schema and existing published Database. Now i have internal routines to arrange some data in this database and i'm going to use Linq to SQL for this. Is it possible to auto-generate model classes from Database project or existing database? I've created mapping XML, but to use it i need to generate classes. Is there any automation?

Upvotes: 0

Views: 1913

Answers (1)

emilpytka
emilpytka

Reputation: 773

This tutorial should help you: http://www.asp.net/mvc/tutorials/older-versions/models-(data)/creating-model-classes-with-linq-to-sql-cs

You have to add add "linq to sql classes" which will generate you models.

Upvotes: 1

Related Questions