Quantcast
Channel: Powertips » ASP.Net
Viewing all articles
Browse latest Browse all 10

How to maintain aspx page position

$
0
0


When working with multiple forms in one page, sometimes you want to stay in the current position after submitting the form. To do this you have options;

  1. MaintainScrollPositionOnPostback set to true – you can set this in web.config to make all pages behave as you want it or you can plug it in the page level.
  2. You can use a javascript
        <script type="text/javascript">
            window.scrollTo = function( x,y ) {
                return true;
            }
        </script>


Viewing all articles
Browse latest Browse all 10

Trending Articles