当前位置: 首页>>代码示例>>C#>>正文


C# System.GetType方法代码示例

本文整理汇总了C#中Common.System.GetType方法的典型用法代码示例。如果您正苦于以下问题:C# System.GetType方法的具体用法?C# System.GetType怎么用?C# System.GetType使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Common.System的用法示例。


在下文中一共展示了System.GetType方法的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: ShowAndRedirect

		/// <summary>
		/// 显示消息提示对话框,并进行页面跳转
		/// </summary>
		/// <param name="page">当前页面指针,一般为this</param>
		/// <param name="msg">提示信息</param>
		/// <param name="url">跳转的目标URL</param>
		public static void ShowAndRedirect(System.Web.UI.Page page,string msg,string url)
		{			
            //Response.Write("<script>alert('帐户审核通过!现在去为企业充值。');window.location=\"" + pageurl + "\"</script>");
            page.ClientScript.RegisterStartupScript(page.GetType(), UnionID().ToString(), "<script language='javascript' defer>alert('" + msg + "');window.location=\"" + url + "\"</script>");


		}
开发者ID:uwitec,项目名称:ds568,代码行数:13,代码来源:MessageBox.cs

示例2: Show

        /// <summary>
        /// 显示消息提示对话框
        /// </summary>
        /// <param name="page">当前页面指针,一般为this</param>
        /// <param name="msg">提示信息</param>
        public static void Show(System.Web.UI.Page page, string msg)
        {
            page.ClientScript.RegisterStartupScript(page.GetType(), "message", "<script language='javascript' defer>alert('" + msg + "');</script>");

            // UpdatePanel采用如下方式弹出对话框
            //System.Web.UI.ScriptManager.RegisterStartupScript(UpdatePanel1, this.GetType(), "javascript", "alert('您已经投过票!');", true);
        }
开发者ID:zachary1986,项目名称:TravelAdmin,代码行数:12,代码来源:MessageBox.cs

示例3: ShowAndRedirects

 /// <summary>
 /// ��ʾ��Ϣ��ʾ�Ի��򣬲�����ҳ����ת
 /// </summary>
 /// <param name="page">��ǰҳ��ָ�룬һ��Ϊthis</param>
 /// <param name="msg">��ʾ��Ϣ</param>
 /// <param name="url">��ת��Ŀ��URL</param>
 public static void ShowAndRedirects(System.Web.UI.Page page, string msg, string url)
 {
     StringBuilder Builder = new StringBuilder();
     Builder.Append("<script language='javascript' defer>");
     Builder.AppendFormat("alert('{0}');", msg);
     Builder.AppendFormat("top.location.href='{0}'", url);
     Builder.Append("</script>");
     page.ClientScript.RegisterStartupScript(page.GetType(), "message", Builder.ToString());
 }
开发者ID:fsfree,项目名称:dookcms,代码行数:15,代码来源:MessageBox.cs

示例4: Show

 /// <summary>
 /// 显示消息提示对话框
 /// </summary>
 /// <param name="page">当前页面指针,一般为this</param>
 /// <param name="msg">提示信息</param>
 public static void Show(System.Web.UI.Page page, messageString msg)
 {
     string str = "";
     switch (msg)
     {
         case messageString.addsuccess:
             str = "添加成功";
             break;
         case messageString.addlose:
             str = "添加失败";
             break;
         case messageString.updatesuccess:
             str = "更新成功";
             break;
         case messageString.updatelose:
             str = "更新失败";
             break;
     }
     page.ClientScript.RegisterStartupScript(page.GetType(), "message", "<script language='javascript' defer>alert('" + str + "');</script>");
 }
开发者ID:wawa0210,项目名称:jgq,代码行数:25,代码来源:MessageBox.cs

示例5: Show

        /// <summary>
        /// 提示框,针对easyUi
        /// </summary>
        /// <param name="page">当前页面指针,一般为this</param>
        /// <param name="script">输出脚本</param>
        /// <param name="script">提示类型</param>
        /// <param name="Fun">回调函数</param>
        public static void Show(System.Web.UI.Page page, string msg, InfoType it,string Fun)
        {
            page.ClientScript.RegisterStartupScript(page.GetType(), UnionID().ToString(), "<script language='javascript' defer>using('messager',function(){$.messager.alert('系统提示','" + msg.Replace("'", "\"").Replace("\n", "").Replace("\r", "") + "。','" + it.ToString() + "'," + Fun + ")});</script>");

        }
开发者ID:uwitec,项目名称:ds568,代码行数:12,代码来源:MessageBox.cs

示例6: ResponseScript

		/// <summary>
		/// 输出自定义脚本信息
		/// </summary>
		/// <param name="page">当前页面指针,一般为this</param>
		/// <param name="script">输出脚本</param>
		public static void ResponseScript(System.Web.UI.Page page,string script)
		{
            page.ClientScript.RegisterStartupScript(page.GetType(), UnionID().ToString(), "<script language='javascript' defer>" + script + "</script>");
             
		}
开发者ID:uwitec,项目名称:ds568,代码行数:10,代码来源:MessageBox.cs

示例7: AlertLocation

 /// <summary>
 /// 自定义脚本信息
 /// </summary>
 /// <param name="page"></param>
 /// <param name="msg"></param>
 public static void AlertLocation(System.Web.UI.Page page, string msg)
 {
     page.ClientScript.RegisterStartupScript(page.GetType(), "msg", "<script>" + msg + "</script>");
 }
开发者ID:MobileApps-BJTU,项目名称:Web,代码行数:9,代码来源:DB.cs

示例8: ShowAndRedirect

 /// <summary>
 /// ��ʾ��Ϣ��ʾ�Ի��򣬲�����ҳ����ת
 /// </summary>
 /// <param name="page">��ǰҳ��ָ�룬һ��Ϊthis</param>
 /// <param name="msg">��ʾ��Ϣ</param>
 /// <param name="url">��ת��Ŀ��URL</param>
 public static void ShowAndRedirect(System.Web.UI.Page page,string msg,string url)
 {
     //Response.Write("<script>alert('�ʻ����ͨ��������ȥΪ��ҵ��ֵ��');window.location=\"" + pageurl + "\"</script>");
     page.ClientScript.RegisterStartupScript(page.GetType(), "message", "<script language='javascript' defer>alert('" + msg + "');window.location=\"" + url + "\"</script>");
 }
开发者ID:fsfree,项目名称:dookcms,代码行数:11,代码来源:MessageBox.cs

示例9: RegisterScriptBlock

 /// <summary>
 /// 注册脚本块
 /// </summary>
 public static void RegisterScriptBlock(System.Web.UI.Page page, string _ScriptString)
 {
     page.ClientScript.RegisterStartupScript(page.GetType(), "scriptblock", "<script type='text/javascript'>" + _ScriptString + "</script>");
 }
开发者ID:vinStar,项目名称:vin_zone_2012,代码行数:7,代码来源:JavascriptHelper.cs

示例10: ShowFailTip

 /// <summary>
 /// 显示操作失败的提示信息
 /// </summary>
 /// <param name="page"></param>
 /// <param name="msg"></param>
 public static void ShowFailTip(System.Web.UI.Page page, string msg)
 {
     page.ClientScript.RegisterStartupScript(page.GetType(), "message", "<script language='javascript' defer>ShowFailTip('" + msg + "');</script>");
 }
开发者ID:zachary1986,项目名称:TravelAdmin,代码行数:9,代码来源:MessageBox.cs

示例11: ShowAndBack

 /// <summary>
 /// 显示消息提示对话框,并返回原页面
 /// </summary>
 /// <param name="page">当前页面指针,一般为this</param>
 /// <param name="msg">提示信息</param>
 public static void ShowAndBack(System.Web.UI.Page page, string msg)
 {
     page.ClientScript.RegisterStartupScript(page.GetType(), "message", "<script language='javascript' defer>alert('" + msg + "');history.back();</script>");
 }
开发者ID:zachary1986,项目名称:TravelAdmin,代码行数:9,代码来源:MessageBox.cs

示例12: ShowSuccessTip

 /// <summary>
 /// 显示操作成功提示信息
 /// </summary>
 /// <param name="page"></param>
 /// <param name="msg"></param>
 public static void ShowSuccessTip(System.Web.UI.Page page, string msg, string url)
 {
     page.ClientScript.RegisterStartupScript(page.GetType(), "message", "<script language='javascript' defer>ShowSuccessTip('" + msg + "');function jump(count){window.setTimeout(function(){count--;if(count>0){jump(count)}else{window.location.href=\"" + url + "\"}},1000)}jump(3);</script>");
 }
开发者ID:zachary1986,项目名称:TravelAdmin,代码行数:9,代码来源:MessageBox.cs

示例13: RunScript

 /// <summary>
 /// 运行客户端JavaScript脚本
 /// </summary>
 /// <param name="ctrl">放置脚本的控件</param>
 /// <param name="code">JavaScript代码</param>
 /// <param name="mode">执行模式</param>
 public static void RunScript(System.Web.UI.Control ctrl, string code,ScriptMode mode)
 {
     if (mode == ScriptMode.BeforeLoad)
     {
         ctrl.Page.ClientScript.RegisterClientScriptBlock(ctrl.GetType(), "jsBlock", code, true);
     }
     else if (mode == ScriptMode.AfterLoad)
     {
         System.Web.UI.HtmlControls.HtmlGenericControl hgc = new System.Web.UI.HtmlControls.HtmlGenericControl();
         hgc.TagName = "div";
         hgc.InnerHtml = "<script type=\"text/javascript\">";
         hgc.InnerHtml += code;
         hgc.InnerHtml += "</script>";
         ctrl.Controls.Add(hgc);
     }
     else
     {
         System.Web.UI.ScriptManager.RegisterClientScriptBlock(ctrl, ctrl.GetType(), "jsBlock", code, true);
     }
 }
开发者ID:jxzly229190,项目名称:YrealWeb_Online,代码行数:26,代码来源:PubFunc.cs


注:本文中的Common.System.GetType方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。