Thursday, March 22, 2012

maintainScrollPositionOnPostBack?

According to an article found via the "4 Cats From Rolla" site, you can maintain the scroll position across postbacks by adding this to the web.congig file:

<pagesmaintainScrollPositionOnPostBack="true" />

However, when I try that (in Visual Web Developer 2005), I get, "Message 1 Could not find schema information for the element 'pages'." and "Message 2 Could not find schema information for the attribute 'maintainScrollPositionOnPostBack'.", etc.

What in Sam Hill is going on here?

try setting themaintainScrollPositionOnPostBack property at the page level instead of in web.config.

you put it in the very top of each page where the <%@. Page %> directive is.

hth,

mcm


Thanks, that does work; I wonder why the app-wide setting in web.config won't go, though--according to the article I read, it should work...

0 comments:

Post a Comment