title: Set Default PageSize of GridView
body: <p>I am trying to override the PageSize property of the grid view to set the default value to 100, but when the code executes it takes the default value defined in the base class. Can anyone please help how can I set my default PageSize. I am extending the gridview control to customize according to my need.
  Here is the code :</p>
  
  <pre><code>    [DefaultValue(100)]
      public override int PageSize
      {
          get
          {
              return base.PageSize;
          }
          set
          {
              base.PageSize = value;
          }
      }
  </code></pre>
  
  <p>Or should I try to set my default Page Sie in some overridden method like.</p>
  
  <pre><code>    protected override void OnInit(EventArgs e)
      {
          base.PageSize = 100;
          base.OnInit(e);
      }
  </code></pre>
  
  <p>Or </p>
  
  <pre><code>    protected override void OnLoad(EventArgs e)
      {
          base.PageSize = 100;
          base.OnLoad(e);
      }
  </code></pre>