Click here to Skip to main content
15,885,872 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,

I want to use Scriptmanager object defined in master page of a class library. That class library is been referred in another web application and the application master page is referencing to class library's master page. Now I want to add a attribute to scriptmanager from the web application. Currently I am doing like this:-

Class Library's code:-

C#
protected void Page_Init(object sender, EventArgs e)
        {
            objscriptManager = new AjaxControlToolkit.ToolkitScriptManager();
            objscriptManager.ID = "scripManager";
            objscriptManager.CombineScripts = false;

         }

Web application code:-
C#
protected void Page_Load(object sender, EventArgs e)
        {
            AdminPage a = new AdminPage();
            a.objscriptManager.EnablePartialRendering = true;
        }


In wen application I am trying to change the "EnablePartialRendering" attribute of scriptmanager to true;

Could some one help me with this code. After doing this I am getting error for Null reference in the web application.

Thanks
Posted

Cant you see "EnablePartialRendering" attribute in the default page directives ?!!

I mean at <%@ Page
 
Share this answer
 
Actually The change which you are asking to do can be done in the dll which is been used in my web application . I have to do some changes in my web application to change EnablePartialRendering to TRUE. Also EnablePartialRendering is not present in <%@ Page directives.

Thanks,
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900