R – form.defaultbutton does not work in Firefox

defaultbuttonfirefoxnet

i am asking this question because my code has the following which works perfectly on IE but not on any other browsers.
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
If Not IsPostBack Then
— my code here —
Form.DefaultButton = Button_new.UniqueID
End Sub

I have used Button_new.ID, Button_new.ClientID and it crashes completely. This is the error I get –

"System.InvalidOperationException: The DefaultButton of 'form1' must be the ID of a control of type IButtonControl."

What can I do to make this work in browsers other than just IE?

Best Answer

I experienced a problem that sounds a lot like what you describe. I solved it by upgrading to the latest service packet (.NET 3.5 SP1).

I recall seeing some people solve issues like this with Javascript code, but was fortunate that the service pack fixed my issue without the need to apply a workaround.