blah blah blah is here! blah blah » Close

up0down
link

How do I maintain the focus on a Web form on a specific control after a post back event?

last answered 2 years ago

1 answers

up0down
link

The simplest way to achieve this is to use the SmartNavigation. To use it, add the SmartNavigation="true" to your page directive:
<%@ Page language="C#" SmartNavigation="true" %>
SmartNavigation not only allow you to retain focus on post back, but also to retain the scroll position. This is quite a handy attribute to allow user to have a good user experience.

This post was imported from csharpfriends, if you have a similiar question please ask it again.

All previous members have been migrated, hope you enjoy the new platform!

Feedback