Solved

Maintaining scroll position (using nested masterpages) on clicking ajax tabContainer

Posted on 2011-02-14
6
1,291 Views
Last Modified: 2012-05-11
For some reason, introducing an AJAX TabContainer with multiple Tabs forces the scroll position to return to 'just below' the top every time a tab panel is changed.

I have exhausted my patience on trying to implement the solution described here
http://weblogs.asp.net/andrewfrederick/archive/2008/03/04/maintain-scroll-position-after-asynchronous-postback.aspx

I assume its got something to do with using nested masterpages. All examples only extend to simple masterpages.

Have the following in my web.config
<pages maintainScrollPositionOnPostBack="true"> blah blah..................
</pages>

Seriously thinking of abandoning tabContainers as have had numerous issues so please help.
0
Comment
Question by:JOHNFROG
  • 4
6 Comments
 
LVL 9

Accepted Solution

by:
xav056 earned 250 total points
ID: 34893561
try removing  maintainScrollPositionOnPostBack="true"> , and see if that is working, a conflicat might be happening between this and the code you pointed to in the link above
0
 
LVL 5

Assisted Solution

by:Eduardo Goicovich
Eduardo Goicovich earned 250 total points
ID: 34893615
what browser are you using?
0
 

Author Comment

by:JOHNFROG
ID: 34893693
have tried removing maintainScrollPositionOnPostBack="true">
from web.config but still cannot maintain scroll position on tab change.

It is worth noting that if I simply refresh the page using F5 then the page WILL return to the last scroll position.

Every other AJAX control does not have this problem unless a tabContainer is on the page.

For instance, I placed a simple radio button on the bottom of the page below the TabContainer with auto postback turned on. When I change the value of the radiobutton it also returns scroll to the top.

Now if I take away the entire TabContainer and add a bunch of </br>'s to take it place but change nothing else, then the changing of the same radiobutton will maintain scroll position.

Any further help will be appreciated and tested but I have already started building my own tab container using buttons and panels. This has its benefits already as I can easily add some ajax animations etc. More flexibility but messy as.

0
NAS Cloud Backup Strategies

This article explains backup scenarios when using network storage. We review the so-called “3-2-1 strategy” and summarize the methods you can use to send NAS data to the cloud

 

Author Comment

by:JOHNFROG
ID: 34893696
using google chrome
0
 

Author Comment

by:JOHNFROG
ID: 34893729
Ahhhh. Just tested on Firefox and position was maintained.

Any chrome specific patches?
0
 

Author Closing Comment

by:JOHNFROG
ID: 34922312
retiring this question due to the browser issue becoming relevant.
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

JavaScript can be used in a browser to change parts of a webpage dynamically. It begins with the following pattern: If condition W is true, do thing X to target Y after event Z. Below are some tips and tricks to help you get started with JavaScript …
This article discusses how to create an extensible mechanism for linked drop downs.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

803 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question