HtmlForm fMp = Master.FindControl("fMp") as HtmlForm;
if (fMp != null)
{
fMp.DefaultButton = btnLogin.UniqueID;
}
but when i press enter nothing happens. Any idea why?
if i use:
fMp.DefaultButton = "btnLogin";
then i get:
The DefaultButton of ‘fMp’ must be the
ID of a control of type
IButtonControl.
isn’t LinkedButton part of IButtonControl. I google but no solution…
Only Button and ImageButton controls are supported as DefaultButton.Check this msdn article if you need to confirm.