locked
creating custom back button RRS feed

  • Question

  • User87328065 posted

    Hey guys,

    I am creating a back button component. Below is the code that i am using, aswel as the link from wich i got it. everytime i try to build it, i get the following error in the BackButton.Designer.cs

     Error 1 'BackButton.BackButton.Dispose(bool)': no suitable method found to override 

     

    using System;
    using System.Web.UI;
    using System.Web.UI.WebControls;
    using System.ComponentModel;
    
    namespace BackButton
    {
        /// <summary>
        /// Summary description for MyBackButton.
        /// </summary>
        [ToolboxData("<{0}:MyBackButton runat=server></{0}:MyBackButton>")]
        public class MyBackButton : System.Web.UI.WebControls.HyperLink
        {
            protected override void OnLoad(EventArgs e)
            {
                if (!Page.IsPostBack)
                    base.NavigateUrl = Page.Request.UrlReferrer.AbsoluteUri;
                base.OnLoad(e);
            }
    
            [Browsable(false)]
            public new string NavigateUrl
            {
                get
                {
                    return base.NavigateUrl;
                }
            }
    
            private void InitializeComponent()
            {
    
            }
        }
    }
    

    please help

    Thursday, July 16, 2009 8:46 AM

All replies