ScriptManager.RegisterStartupScript
is used only together with UpdatePanels, which I didn't use on my page. Instead I found a solution based on getting the actual RadAjaxManagerProxy
for the page. This was done by using the function GetCurrent()
on the MasterPage's RadAjaxManager
. Hopefully this will save some hours for anyone else with the same problem! My solution:
RadAjaxManager.GetCurrent(Page).ResponseScripts.Add("window.scrollTo(0, 0);");