MaintainScrollPositionOnPostback = "true" does not work globally after setting in web.config, but it works at the page level, what should I do?

setting maintainScrollPositionOnPostback = "true" globally in web.config works in my xp sp3 in iis 5.1, but not for the production server (win server 2003 sp2 with .NET 3.5 sp1 and IIS 6).

but if add MaintainScrollPositionOnPostback = "true" for any directive <% @page, it works like a champion.

I don't know if I have to add a shortcut for web.config to override it in IIS 6 or something like that?

Any tips, advice or comments would be appreciated.

here is the related section in web.config

<pages maintainScrollPositionOnPostBack="true" validateRequest="false" enableEventValidation="false" viewStateEncryptionMode="Never" enableViewStateMac="false" > <controls> .... </controls> </pages> 

-------- update ---------

I don’t know what the real problem was when I submit the question, right now I have no problems supporting ScrollPositionOnPostback = "true" in my new windows 7 system.

+1
source share
3 answers

case-sensitive issue may occur - try maintainScrollPositionOnPostback (lowercase m )

+2
source

I had a similar problem. But after checking the markup, it turned out that the problem was related to one of the update panels. Check the update panels if you have a similar problem.

+1
source

Hi, I found a solution on Javascript file

Just add to the header file after the jquery library

I think this will solve your problem, his work is perfect for me.

0
source

Source: https://habr.com/ru/post/897197/


All Articles