Search code examples
c#asp.netfocusenterprise-web-library

How to set form field focus on page load in EWL?


I want to set focus to a particular form field on page load. This will be the same form field every time the page is loaded, even after posting-back a data modification. Is this possible?


Solution

  • Yes. Override EwfPage.controlWithInitialFocus. This property is called after LoadData.