views:

285

answers:

3

i try to learn learn Dynamic Data Entties . i see some sample about it. they try to teach some codes in App_code. i really want to learn where is my Ap_code?

A: 

Hi ! It seems it is not possible to create the app_code folder. Take a look at the bottom of this page in the community content part. There are a lot of people with the same problem.

SOLUTION: add the .dbml to file root of the site

João Guilherme
+1  A: 

Web Applications do not use the App_Code folder, only Web Sites. If you want to use the App_Code folder create a Web Site instead of a new Web Application.

If you want to use a Web Application you can place the .dbml file anywhere, you'll just have to fully qualify (with namespaces) the DataContext wherever you want to use it (ex: in the Global.asax file).

Aaron Hoffman
A: 

As mentioned above, a web app project does not create an App_Code folder by default. You can create one using the solution explorer though if you want - right click on web project, new folder..., name it App_Code.

Rob
But be aware - when you add classes to that folder they may be added to the "[DefaultNamespace].App_Code" namespace by default.
Aaron Hoffman
Problem is not App_code? i need metadata.cs. i need it because i really want to add some property . i read alot of things . i think rhat i have a problem metara.cs ?
Phsika