How to add a default Default.aspx to a ASP.NET Web Application Project? [closed]

扶醉桌前 提交于 2020-01-26 04:21:08

问题


I am working with Visual Studio 2015.

I created a new ASP.NET Web Application project. Then get a screen to Select a template. I selected Empty.

The Project named WebApplication1 is created. It has 2 files

  1. packages.config
  2. Web.config

But it does not have Default.aspx. I remember older version of Visual Studio used to create Default.aspx automatically. So how can I add it?


回答1:


Follow these simple steps:

  1. Right click your project
  2. Click on New
  3. Select Web Form
  4. Write Default.aspx as name



回答2:


An empty template now means that you want project with no server/client file. If you want to add a Default.aspx, that means that you would like to create a Webform project. You can just:

Right click on the WebApplication1 project -> click on Add -> New Item -> Then select Web Form (change the name from WebForm1.aspx to Default.aspx)



来源:https://stackoverflow.com/questions/34008880/how-to-add-a-default-default-aspx-to-a-asp-net-web-application-project

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!