Positioning a form by scrollto after loading the form

After loading an HTML Template the form its shown at the bottom. i want that the form is on top postion after loading the form.
When i use the window.scrollto(0,0) command by webbutton its all ok.
Is there a possibilty to wait until the form is loaded. the onshow event seems not to by the right place.

Or is there another way to force the the form after loading to top position?

Did you try to call this from the form.OnShow event?

Yes I placed this code in the on show event. Is There a other possibilty to wait for the complete loading of the site?

Do you see an error in the browser console?

no error in the browser

I find it best to use a timer with a very short delay and enable it in the onshow event.

Ok, I try this