void History_Navigate(object sender, HistoryEventArgs e)
 {
     if (e.State.HasKeys())
     {
         gridManage.CurrentPageIndex = int.Parse(e.State["page"]);
     }
     gridManage_OnGetDataSource(sender, e);
     gridManage.DataBind();
 }
Пример #2
0
 /// <summary>
 /// Handles the Navigate event of the sm control.
 /// </summary>
 /// <param name="sender">The source of the event.</param>
 /// <param name="e">The <see cref="HistoryEventArgs"/> instance containing the event data.</param>
 public void sm_Navigate( object sender, HistoryEventArgs e )
 {
     // show the view mode
     pnlGroupEdit.Visible = false;
     pnlGroupView.Visible = true;
     pnlEditGroupMember.Visible = false;
     DisplayViewGroup();
 }
Пример #3
0
 /// <summary>
 /// Handles the Navigate event of the scriptManager control.
 /// </summary>
 /// <param name="sender">The source of the event.</param>
 /// <param name="e">The <see cref="HistoryEventArgs"/> instance containing the event data.</param>
 protected void scriptManager_Navigate( object sender, HistoryEventArgs e )
 {
     if ( PageNavigate != null )
     {
         PageNavigate( this, e );
     }
 }
Пример #4
0
 void History_Navigate(object sender, HistoryEventArgs e)
 {
     if (e.State.HasKeys())
     {
         LocationWithOptionsEventArgs l_args = new LocationWithOptionsEventArgs(e.State);
         l_args.Clear = true;
         LocationSelector.SelectLocation(sender, l_args);
         gridManage.CurrentPageIndex = int.Parse(e.State["page"]);
         inputName.Text = e.State["name"];
         atoz.SelectIfChar(inputName.Text);
     }
     else
     {
         LocationSelector.ClearSelection();
         inputName.Text = string.Empty;
         atoz.ClearSelection();
     }
     gridManage_OnGetDataSource(sender, e);
     gridManage.DataBind();
 }
Пример #5
0
        private void scriptManager_Navigate(object sender, HistoryEventArgs e)
        {
            if (!pnlMailBox.Visible) return;

            int historyPage = 0;
            try
            {
                historyPage = Convert.ToInt32(e.State["page"] ?? "1");
            }
            catch (FormatException)
            {
            }
            if (historyPage < 0 || historyPage > Results.GetTotalPages(10)) historyPage = 0;

            updateHistory = false;
            CurrentPage = historyPage;
            if (e.State["currentFolder"] != null)
                currentFolder = (Message.eFolder)Convert.ToInt32(e.State["currentFolder"]);
            bindMessages();
        }
Пример #6
0
 public void FileManagerControl_FileManagerControl_Navigate(object sender, HistoryEventArgs e)
 {
     NavigateTo(e.State["path"]);
 }
        void page_PageNavigate( object sender, HistoryEventArgs e )
        {
            string stateData = e.State["Exception"];

            int exceptionId = 0;
            int.TryParse( stateData, out exceptionId );

            SetExceptionPanelVisibility( exceptionId );
        }
Пример #8
0
        void scriptManager_Navigate(object sender, HistoryEventArgs e)
        {
            if (Results == null)
                Response.Redirect("~/Home.aspx");

            int navigatePage;
            try
            {
                navigatePage = e.State.Count == 0 ? 1 : Convert.ToInt32(e.State[0]);
            }
            catch (FormatException)
            {
                navigatePage = 1;
            }
            int usersPerPage = dlUsers.Visible ? Config.Search.UsersPerPage : Config.Search.UsersPerPageGrid;
            if (navigatePage <= Results.GetTotalPages(usersPerPage)
                && navigatePage > 0)
            {
                updateHistory = false;
                CurrentPage = navigatePage;
            }
        }
Пример #9
0
        void scriptManager_Navigate(object sender, HistoryEventArgs e)
        {
            if (DisplayResults == null)
                return;

            int navigatePage;
            try
            {
                navigatePage = e.State.Count == 0 ? 1 : Convert.ToInt32(e.State[0]);
            }
            catch (FormatException)
            {
                navigatePage = 1;
            }
            int usersPerPage = dlGiftsGallery.Visible ? Config.Gift.GiftsPerPage: 0;
            if (navigatePage <= DisplayResults.Length && navigatePage > 0)
            {
                _updateHistory = false;
                CurrentPage = navigatePage;
            }
        }
Пример #10
0
 /// <summary>
 /// Handles the history state to allow the back button to work in the update panel.
 /// </summary>
 /// <param name="sender">The source of the event.</param>
 /// <param name="e">The <see cref="System.Web.UI.HistoryEventArgs"/> instance containing the history data.</param>
 void page_PageNavigate(object sender, HistoryEventArgs e)
 {
     SetEditMode(false);
 }
Пример #11
0
 void page_PageNavigate( object sender, HistoryEventArgs e )
 {
     pnlDetails.Visible = false;
     pnlList.Visible = true;
     hfEntityTypeId.Value = string.Empty;
 }
Пример #12
0
		private void HistoryNavigator_Navigate(object sender, HistoryEventArgs e)
		{
			if (ScriptManager.IsInAsyncPostBack)
			{
				StateController.NavigateHistory(e.State);
			}
		}
Пример #13
0
        private void scriptManager_Navigate(object sender, HistoryEventArgs e)
        {
            if (!pnlMailBox.Visible) return;

            int historyPage = 0;
            try
            {
                historyPage = e.State.Count == 0 ? 1 : Convert.ToInt32(e.State[0]);
            }
            catch (FormatException)
            {
            }
            if (historyPage < 0 || historyPage > Results.GetTotalPages(10)) historyPage = 0;

            updateHistory = false;
            CurrentPage = historyPage;
            bindMessages();
        }
Пример #14
0
        private void Sm_Navigate( object sender, HistoryEventArgs e )
        {
            var state = e.State["form"];

            if ( state != null )
            {
                CurrentPageIndex = state.AsInteger();
            }
            else
            {
                CurrentPageIndex = 0;
            }

            ShowPage();
        }
Пример #15
0
        /// <summary>
        /// Handles the Navigate event of the sm control.
        /// </summary>
        /// <param name="sender">The source of the event.</param>
        /// <param name="e">The <see cref="HistoryEventArgs"/> instance containing the event data.</param>
        void sm_Navigate( object sender, HistoryEventArgs e )
        {
            var state = e.State["event"];

            if ( CurrentPanel > 0 && state != null )
            {
                string[] commands = state.Split( ',' );

                int panelId = 0;
                int registrantId = 0;
                int formId = 0;

                if ( commands.Count() == 3 )
                {
                    panelId = Int32.Parse( commands[0] );
                    registrantId = Int32.Parse( commands[1] );
                    formId = Int32.Parse( commands[2] );
                }

                switch ( panelId )
                {
                    case 1:
                        {
                            CurrentRegistrantIndex = registrantId;
                            CurrentFormIndex = formId;

                            this.ProgressBarSteps = numHowMany.Value * FormCount + 2;
                            PercentComplete = ( ( (double)2 + ( ( CurrentFormIndex + 1) * CurrentRegistrantIndex ) ) / (double)ProgressBarSteps ) * 100;

                            ShowRegistrant();
                            break;
                        }
                    case 2:
                        {
                            ShowSummary();
                            break;
                        }
                    default:
                        {
                            ShowHowMany();
                            break;
                        }
                }
            }
            else
            {
                ShowHowMany();
            }
        }
Пример #16
0
        void scriptManager_Navigate(object sender, HistoryEventArgs e)
        {
            if (UserPhotosIDs.Length == 0)
                Response.Redirect("Home.aspx");

            int navigatePage;
            try
            {
                navigatePage = e.State.Count == 0 ? 1 : Convert.ToInt32(e.State[0]);
            }
            catch (FormatException)
            {
                navigatePage = 1;
            }
            if (navigatePage <= UserPhotosIDs.Length && navigatePage > 0)
            {
                updateHistory = false;
                CurrentPhoto = navigatePage;
            }
        }
Пример #17
0
        void scriptManager_Navigate(object sender, HistoryEventArgs e)
        {
            if (VideoUploadResults == null && VideoEmbedResults == null)
                Response.Redirect("~/Home.aspx");

            int navigatePage;
            try
            {
                navigatePage = e.State.Count == 0 ? 1 : Convert.ToInt32(e.State[0]);
            }
            catch (FormatException)
            {
                navigatePage = 1;
            }
            int videosPerPage = Config.Search.VideosPerPage;
            if (VideoUploadResults != null)
            {
                if (navigatePage <= VideoUploadResults.GetTotalPages(videosPerPage) && navigatePage > 0)
                {
                    updateHistory = false;
                    CurrentPage = navigatePage;
                }
            }
            else if (VideoEmbedResults != null)
            {
                if (navigatePage <= VideoEmbedResults.GetTotalPages(videosPerPage) && navigatePage > 0)
                {
                    updateHistory = false;
                    CurrentPage = navigatePage;
                }
            }
        }
        protected void MainScriptManager_Navigate(object sender, HistoryEventArgs e)
        {
            if ((rdobtnlstQ4.SelectedValue == "1") || (rdobtnlstQ4.SelectedValue == "2"))
            {
                Q5_li.Visible = false;
                rdobtnlstQ5.Visible = false;
                lblQ5.Visible = false;
                txtBestDescribesEducation.Visible = false;
            }
            else
            {
                Q5_li.Visible = true;
                rdobtnlstQ5.Visible = true;
                lblQ5.Visible = true;
                txtBestDescribesEducation.Visible = true;
            }

            if (txtQ12.Text == "0")
            {
                lblQ13.Visible = false;
                Q13_li.Visible = false;
            }
            else
            {
                lblQ13.Visible = true;
                Q13_li.Visible = true;
            }
        }
Пример #19
0
        /// <summary>
        /// Handles the Navigate event of the sm control.
        /// </summary>
        /// <param name="sender">The source of the event.</param>
        /// <param name="e">The <see cref="HistoryEventArgs"/> instance containing the event data.</param>
        void sm_Navigate( object sender, HistoryEventArgs e )
        {
            var state = e.State["event"];

            if ( state != null )
            {
                string[] commands = state.Split( ',' );

                int panelId = 0;
                int registrantId = 0;
                int formId = 0;

                if ( commands.Count() == 3 )
                {
                    panelId = Int32.Parse( commands[0] );
                    registrantId = Int32.Parse( commands[1] );
                    formId = Int32.Parse( commands[2] );
                }

                switch ( panelId )
                {
                    case 1:
                        {
                            CurrentRegistrantIndex = registrantId;
                            CurrentFormIndex = formId;
                            ShowRegistrant();
                            break;
                        }
                    case 2:
                        {
                            ShowSummary();
                            break;
                        }
                    default:
                        {
                            ShowHowMany();
                            break;
                        }
                }
            }
            else
            {
                ShowHowMany();
            }
        }
Пример #20
0
    void History_Navigate(object sender, HistoryEventArgs e)
    {
        if (e.State.HasKeys())
        {
            LocationWithOptionsEventArgs l_args = new LocationWithOptionsEventArgs(e.State);
            l_args.Clear = true;
            LocationSelector.SelectLocation(sender, l_args);
            gridManage.CurrentPageIndex = int.Parse(e.State["page"]);
        }

        gridManage_OnGetDataSource(sender, e);
        gridManage.DataBind();
    }
Пример #21
0
 /// <summary>
 /// Handles the PageNavigate event of the page control.
 /// </summary>
 /// <param name="sender">The source of the event.</param>
 /// <param name="e">The <see cref="HistoryEventArgs"/> instance containing the event data.</param>
 protected void page_PageNavigate( object sender, HistoryEventArgs e )
 {
     int pageId = e.State["GivingDetail"].AsInteger();
     if ( pageId > 0 )
     {
         SetPage( pageId );
     }
 }
 //protected void lbBack_Click( object sender, EventArgs e )
 //{
 //    pnlPackageList.Visible = true;
 //    pnlPackage.Visible = false;
 //    BindPackageListGrid();
 //}
 void page_PageNavigate( object sender, HistoryEventArgs e )
 {
     if ( e.State["CurrentViewMode"] != null )
     {
         this.CurrentViewMode = (ViewMode)Enum.Parse( typeof( ViewMode ), e.State["CurrentViewMode"] );
     }
     else
     {
         this.CurrentViewMode = ViewMode.Installed;
     }
     pnlPackageList.Visible = true;
     pnlPackage.Visible = false;
     BindPackageListGrid();
 }
Пример #23
0
        protected void ScriptManager1_Navigate(object sender, HistoryEventArgs e)
        {
            if (e.State.Count <= 0)
            {
                this.ViewState["vs"] = 0;
                pnlCategories.Visible = true;
                pnlProducts.Visible = true;
                pnlDetails.Visible = false;
                pnlCheckOut.Visible = false;
                GetCategory();
                GetProducts(0);
                return;
            }

            string key = e.State.AllKeys[0];
            string state = String.Empty;

            if (String.Equals(key, pageKey))
            {
                state = e.State[key];
                int pageIndex = Convert.ToInt32(state);
                this.ViewState["vs"] = pageIndex;
                GetProducts(0);
            }
            if (String.Equals(key, modeKey))
            {
                state = e.State[key];
                GetProducts(Convert.ToInt32(state));
            }
            if (String.Equals(key, deltaKey))
            {
                state = e.State[key];
                GetProducts(Convert.ToInt32(state));
            }
        }
 protected void ScriptManager_Navigate(object sender, HistoryEventArgs e)
 {
     SortAndFilterPanel.Update();
 }