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


C# Util.ResetAppStateVariables方法代码示例

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


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

示例1: ManageDataApps_SelectedIndexChanged

    /***************************************** Common Functions *******************************/
    public void ManageDataApps_SelectedIndexChanged(object sender, EventArgs e)
    {
        Util util = new Util();
        Hashtable State = (Hashtable)HttpRuntime.Cache[Session.SessionID];
        if (util.CheckSessionTimeout(State, Response, "Default.aspx")) return;

        ClearMessages();

         State["ManageDataType"] = null;
        string app_name = Request.Form.Get("ManageDataApps");
        if (!app_name.Contains("->"))
        {
             State["SelectedApp"] = app_name;
            ManageDataApps.SelectedValue = app_name;
            InitDataTrees(app_name);
            ViewStoryBoard.Style.Value = "";
            ManageDataType.Style.Value = "";
            ManageDataTypeLabel.Style.Value = "";
        }
        else
        {
            ManageDataType.Style.Value = "display:none";
            ManageDataTypeLabel.Style.Value = "display:none";
            ViewStoryBoard.Style.Value = "display:none";
            util.ResetAppStateVariables(State);
            ContentMultiPage.SelectedIndex = 0;
            ShouldRefreshStoryBoard.Text = "close";
            Init init = new Init();
            init.InitManageDataAppsList(State);
            DataMultiPage.SelectedIndex = 3;
        }
    }
开发者ID:dcolonvizi,项目名称:ViziAppsPortal,代码行数:33,代码来源:ManageData.aspx.cs

示例2: MySolutions_ItemDeleted

    protected void MySolutions_ItemDeleted(object source, GridDeletedEventArgs e)
    {
        Util util = new Util();
        Hashtable State = (Hashtable)HttpRuntime.Cache[Session.SessionID];
        if (util.CheckSessionTimeout(State, Response, "Default.aspx")) return;

        int row = e.Item.ItemIndex;
           // RadGrid MySolutions = (RadGrid) State["MySolutions"];
        string app = MySolutions.Items[row].Cells[2].Text;
        //delete app
        State["SelectedApp"] = app;
        util.DeleteApplication(State);
        util.ResetAppStateVariables(State);
        LoadData();
    }
开发者ID:dcolonvizi,项目名称:ViziAppsPortal,代码行数:15,代码来源:TabMySolutions.aspx.cs

示例3: SetProvisionButtons

    protected void SetProvisionButtons(string app_name)
    {
        Util util = new Util();
        Hashtable State = (Hashtable)HttpRuntime.Cache[Session.SessionID];
        if (util.CheckSessionTimeout(State, Response, "Default.aspx")) return;

        if (State["SelectedApp"] == null)
        {
            util.ResetAppStateVariables(State);
            ProvisionApps.SelectedIndex = 0;
            ProvisionToStagingButton.Style.Value = "display:none";
            SeePublishingFormButton.Style.Value = "display:none"; ;

            return;
        }

        ClearMessages();

        if (!app_name.Contains("->"))
        {
            if (util.IsAppSelectedForTest(State))
            {
                ProvisionMessage.Text =  State["SelectedApp"].ToString() + " has been provisioned for testing";
                ProvisionToStagingButton.Style.Value = "display:none";
            }
            else
                ProvisionToStagingButton.Style.Value = "";

             SeePublishingFormButton.Style.Value = "";
             SetProvisionFormPopup();
        }
        else
        {
             State["SelectedApp"] = null;
             State["SelectedAppType"] = null;
            util.ResetAppStateVariables(State);
            ProvisionApps.SelectedIndex = 0;
            ProvisionToStagingButton.Style.Value = "display:none";
            SeePublishingFormButton.Style.Value = "display:none";;
        }
    }
开发者ID:dcolonvizi,项目名称:ViziAppsPortal,代码行数:41,代码来源:TabPublishOld.aspx.cs

示例4: Page_Load

    protected void Page_Load(object sender, EventArgs e)
    {
        Util util = new Util();
        Hashtable State = (Hashtable)HttpRuntime.Cache[Session.SessionID];
        if (util.CheckSessionTimeout(State,Response,"Default.aspx")) return;
        try
        {
            if ( HttpRuntime.Cache["TechSupportEmail"] != null)
            {
                util.AddEmailToButton(SupportButton,  HttpRuntime.Cache["TechSupportEmail"].ToString(), "Email To Tech Support");
            }

            util.UpdateSessionLog(State, "post", "TabMySolutions");

            ClearMessages();

            DemoVideo.Attributes.Add("onclick", PopupHelper.GeneratePopupScript(
                 "Help/MySolutions/DemoVideo.htm", 400, 655, false, false, false, true));
            DemoVideo1.Attributes.Add("onclick", PopupHelper.GeneratePopupScript(
                 "Help/MySolutions/DemoVideo.htm", 400, 655, false, false, false, true));
            QuickStart.Attributes.Add("onclick", PopupHelper.GeneratePopupScript(
                 "Help/MySolutions/QuickStart.aspx", 940, 750, false, false, false, true));
            QuickStart1.Attributes.Add("onclick", PopupHelper.GeneratePopupScript(
                  "Help/MySolutions/QuickStart.aspx", 940, 750, false, false, false, true));
            YourFirstApp.Attributes.Add("onclick", PopupHelper.GeneratePopupScript(
                 "Help/MySolutions/YourFirstApp.htm", 350, 650, false, false, false, true));
            YourFirstApp1.Attributes.Add("onclick", PopupHelper.GeneratePopupScript(
                 "Help/MySolutions/YourFirstApp.htm", 350, 650, false, false, false, true));
            Overview.Attributes.Add("onclick", PopupHelper.GeneratePopupScript(
                 "Help/MySolutions/Overview.aspx", 800, 800, false, false, false, true));
            Overview1.Attributes.Add("onclick", PopupHelper.GeneratePopupScript(
                 "Help/MySolutions/Overview.aspx", 800, 800, false, false, false, true));

            if (IsPostBack)
            {
                if (Request.Form.AllKeys.Length > 0)
                {
                    int last = Request.Form.AllKeys.Length - 1;

                    for (int i = last; i > last - 3; i--)
                    {
                        if (Request.Form.AllKeys[i] != null && Request.Form.AllKeys[i].Contains("$delete."))
                        {
                            int start = Request.Form.AllKeys[i].IndexOf("$delete.") + 8;
                            string[] split = Request.Form.AllKeys[i].Substring(start).Split(".".ToCharArray());
                            int row = Convert.ToInt32(split[0]);
                            string app = MySolutions.Items[row].Cells[2].Text;
                            //delete app
                            State["SelectedApp"] = app;
                            util.DeleteApplication(State);
                            util.ResetAppStateVariables(State);
                            LoadData();
                            return;
                        }
                    }
                }
            }
            else
            {
                CopyRight.InnerText = HttpRuntime.Cache["CopyRight"].ToString();
                UserLabel.Text = State["Username"].ToString();
                LoadData();
            }

        }
        catch (Exception ex)
        {
            util.ProcessMainExceptions(State, Response, ex);
        }
    }
开发者ID:dcolonvizi,项目名称:ViziAppsPortal,代码行数:70,代码来源:TabMySolutions.aspx.cs


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