使用网站项目在 Visual Studio Dev Server 上设置静态端口号 [英] Setting static port number on Visual Studio Dev Server with a WebSite project

查看:28
本文介绍了使用网站项目在 Visual Studio Dev Server 上设置静态端口号的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在 Visual Studio 2008 中有一个网站项目(不是 Web 应用程序项目!)

I have a WebSite project in Visual Studio 2008 (not a Web Application project!)

如何在网站项目中将 ASP.NET Development 启动端口设置为静态端口?

How do I set the ASP.NET Development startup port to a static port in a WebSite project?

推荐答案

为 ASP.NET 开发服务器指定端口 - WebSite/WebServices 项目

To specify a port for the ASP.NET Development Server - WebSite / WebServices projects

  1. 在解决方案资源管理器中,单击应用程序的名称.
  2. 在属性"窗格中,单击使用动态端口并从下拉列表.这将启用编辑端口号属性.
  3. 在属性"窗格中,单击端口号"旁边的文本框并键入在一个端口号.单击外部属性窗格.这会保存属性设置.
  4. 每次运行文件系统时Visual Web Developer 中的网站,ASP.NET
    开发服务器将侦听指定的端口.
  1. In Solution Explorer, click the name of the application.
  2. In the Properties pane, click the down-arrow beside Use dynamic ports and select False from the dropdown list. This will enable editing of the Port number property.
  3. In the Properties pane, click the text box beside Port number and type in a port number. Click outside of the Properties pane.This saves the property settings.
  4. Each time you run a file-system Web site within Visual Web Developer, the ASP.NET
    Development Server will listen on the specified port.

这篇关于使用网站项目在 Visual Studio Dev Server 上设置静态端口号的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆