I have a script manager on my Master page. There are one or 2 content pages that I need to remove the webresourse.axd from, as it is causing issues with other javascript on the page
How can I disable the script manager on these pages?
The ScriptManager object doesnt appear to have any properties that would seem like they would do the job
Is this possible?
Move your <asp:ScriptManager /> to a custom control e.g. MyScriptManager.ascx – the only code in the .ascx file will be the ScriptManager tag – then you can set the Visible property on your custom control to control whether the ScriptManager gets rendered.
You could maybe even add a Property to your MasterPage which you could use in your content pages to show / hide the ScriptManager:
As most of your pages require the ScriptManager, it might be an idea to make it default to true – I think you can do this in your Master Page’s constructor of Page_Init method:
Then, if you’ve set the MasterType in your content pages:
You just need to do something like this in content page’s Page_Load: