//------------------------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All Rights Reserved. //------------------------------------------------------------------------------ namespace Microsoft.VisualStudio.WebHost { using System; using System.Collections; using System.Globalization; using System.Text; using System.Web; internal class Messages { private const String _httpErrorFormat1 = @" {0} "; public static String VersionString = "1.0"; //typeof(Server).Assembly.GetName().Version.ToString(); private const String _httpStyle = @" "; private static String _httpErrorFormat2 = @"

Server Error in '{0}' Application.

HTTP Error {1} - {2}.


Version Information: Visual Web Developer Web Server " + VersionString + @" "; public static String FormatErrorMessageBody(int statusCode, String appName) { string desc = HttpWorkerRequest.GetStatusDescription(statusCode); return String.Format(_httpErrorFormat1, new object[] {desc}) + _httpStyle + String.Format(_httpErrorFormat2, new object[] {appName, statusCode, desc}); } } }