Link to home
Start Free TrialLog in
Avatar of crickpaolo
crickpaolo

asked on

How do I scroll to the top of an ASP.NET page after postback?

Hi Experts,

I use this on top of my ASP.NET page to maintain the scroll position after postback.

<%@ Page Language="VB" MaintainScrollPositionOnPostback="true" %>

This comes in handy because I have a long form, with Listboxes that do Autopostabacks.  When I click the Submit button though, I want to page to scroll back to the top of the page, because any error messages are displayed on the top of the page.

How can I accomplish this?
ASKER CERTIFIED SOLUTION
Avatar of Toms Edison
Toms Edison
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of crickpaolo
crickpaolo

ASKER

perfect! thanks!