Detect development server in asp.net (Visual Studio)
问题 Can you programatically detect if the Development server in Visual Studio is used instead of IIS? 回答1: In Visual Studio 2010, Request.ServerVariables("SERVER_SOFTWARE") will return Nothing (null) for the Development Server, and "Microsoft-IIS/7.5" for my Win7 Pro IIS/VS2010 installation. 来源: https://stackoverflow.com/questions/3500700/detect-development-server-in-asp-net-visual-studio