Reset Scroll Position

Asked By vimal percy
25-Aug-06 03:17 AM
Earn up to 0 extra points for answering this tough question.
Hello I have 2 pages I is the Parent page which contains fixed set of contents and IFrame is the child page which i use to do the functionalities. Now when i click save in IFrame it submits the page and keep the same scroll position after post back. I tried all possible way to get that page load from Top ie Top and left scroll postion is 0,0. But it always loads with the old scroll position the page was in I have also set Page.MaintainScrollPositionOnPostBack = False and still no luck. Thanks for the help

  smart navigation works

Asked By K Pravin Kumar Reddy
25-Aug-06 04:57 AM
hello To avoid this, ASP.NET provides the SmartNavigation property for the page which takes care of the scroll position. SmartNavigation also avoids the flickering of the page when the page is reloaded. It can be enabled by simply setting its value to true in the page directive, as follows:- <%Page smartNavigation="True" %> Alternatively, it can be specified as a global setting in the web.config as follows:- <configuration> <system.web> <pages smartNavigation="true"/> </system.web> </configuration> in ur looking smartnavigation using javascript check it http://www.codeproject.com/useritems/smartnavwebctrls.asp

  Smart Navigation is obsolete

Asked By vimal percy
25-Aug-06 07:01 AM
I tried using Smartnavigation but the complier says SmartNavigation is obsolete and recommends setfocus or maintain scrollpositiononpostback. But i tried both of them and it doesnt work at all. Need help

  RE:Use MaintainScrollPositionOnPostback

Asked By Sushila Patel
25-Aug-06 09:30 AM
<%@ Page MaintainScrollPositionOnPostback=”true”>
  check out
Asked By K Pravin Kumar Reddy
25-Aug-06 08:52 PM
hello i gave u other link in that check that , u can do that using javascript...
Create New Account