APP_ code文件夹丢失在VS 2010中 [英] App_Code folder is missing in VS 2010
问题描述
我试图创建一个使用VS 2010 RC动态数据网站。试图创造一个APP_ code文件夹,我把一个LINQ to SQL类,失败了。当我选择了添加文件夹ASP.NET添加的文件夹,我只好选择只创建以下文件夹:
I was trying to create a Dynamic Data Website using VS 2010 RC. An attempt to create an App_Code folder where I would put a LINQ to SQL class, failed. When I selected 'Add ASP.NET Folder' to add the folder, I had options to create only the following folders:
- App_GlobalResources文件
- App_LocalResources文件
- 的App_Data li>
- App_Browsers文件
- 主题
发生了什么事APP_ code文件夹?
What happened to the App_Code folder?
推荐答案
为什么不创建另一个项目,一个类库,并把它放在那里。这是迄今为止,以保持这些类从您的网站的其余部分分开的最佳方式。
Why not create another project, a class library, and put it in there. That's by far the best way to keep those classes separate from the rest of your website.
要回答你关于APP_ code文件夹中的具体问题,它在网页项目,你可以选择一个Asp.Net文件夹中。但是,从一个Web应用程序项目,你可以创建一个新的文件夹并将其命名为APP_ code,它会工作得很好。这是因为Visual Studio 2010中的RC。
To answer your specific question about the App_Code folder, it's available in WebSite projects as an Asp.Net folder you can choose from. But from a web application project, you can just create a new folder and name it App_Code and it will work just fine. This is as of Visual Studio 2010 RC.
这篇关于APP_ code文件夹丢失在VS 2010中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!