showexception.cs

来自「1、用SQL查询器打开install目录下的dooogo.sql运行之后创建数据」· CS 代码 · 共 35 行

CS
35
字号
using System;
using System.Web;
using Club.Framework.Configuration;
namespace Club.Framework
{
	/// <summary>
	/// Exception 的摘要说明。
	/// </summary>
	public class ShowException:ApplicationException
	{
		/// <summary>
		/// 异常触发过程 
		/// </summary>
		public ShowException(string message,string backUrl)
		{
			HttpContext.Current.Response.Redirect(Globals.GetWebPath(Config.ShowMessage)+"?Url="+backUrl+"&Message="+message,true);
		}
		public ShowException(string message)
		{
			HttpContext.Current.Response.Redirect(Globals.GetWebPath(Config.ShowMessage)+"?Url="+HttpContext.Current.Request.RawUrl+"&Message="+message,true);
		}
		public ShowException(string message,bool isClose)
		{
			if(isClose)
			{
				HttpContext.Current.Response.Redirect(Globals.GetWebPath(Config.ShowMessage)+"?Message="+message,true);
			}
			else
			{
				HttpContext.Current.Response.Redirect(Globals.GetWebPath(Config.ShowMessage)+"?Url="+HttpContext.Current.Request.RawUrl+"&Message="+message,true);
			}
		}
	}
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?