This is a migrated thread and some comments may be shown as answers.

Set controls status present outside the grid on grid event

3 Answers 48 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Manaswinee
Top achievements
Rank 1
Manaswinee asked on 19 Nov 2010, 06:38 AM

Hello,
I have one ajaxified radgrid which is getting ajaxified through RadAjaxManager.Outside the grid I have two asp buttons.On pageload I am adding ajaxsettings for those buttons.On grid inline edit I am trying to disable those buttons.Those buttons are getting disabled.But I am getting null object exception on clicking the button.If I remove the ajaxsettings from pageload everything works fine but the buttons are not getting disabled.Please suggest me at your earliest...Below are the code in page_load.



 

protected void Page_Load(object sender, EventArgs e)

 

{

 

  RadAjaxMgriPur.AjaxSettings.AddAjaxSetting(RGridImportedData, btnCreateOrder,

null);

 

 

 

  RadAjaxMgriPur.AjaxSettings.AddAjaxSetting(btnCreateOrder, RGridImportedData, RadAjaxLoadingPaneliPur);

 

}


 

 

protected void btnCreateOrder_Click(object sender, EventArgs e)

 

{
     //some operations....
   

 

RGridImportedData.Rebind();

 

}

Thanks in advance.

Manaswinee

3 Answers, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 20 Nov 2010, 07:22 AM
Hello Manaswinee,


Try disabling/enabling the control in RequestStart()/ResponseEnd() events as shown in the documentation.
documentation


Hope this would shed some light on accomplishing the required.


-Shinu.
0
Manaswinee
Top achievements
Rank 1
answered on 20 Nov 2010, 08:58 AM
Hello Shinu,
              I  tried  for the same.But no luck.For your information my page contains a radupload control also for uploading of files.I am able to snable and disable the status of the controls.But on clicking the button I am getting 'null' is null not an object error....Kindly suggest.

Best Regards,
Manaswinee.
0
Radoslav
Telerik team
answered on 24 Nov 2010, 09:53 AM
Hi Manaswinee,

I am sending you a simple example which demonstrates the desired functionality, however everything works as expected and there in not error when the button is clicked. Could you please check the example and let me know what differs in your case.
Looking forward for your reply.

Sincerely yours,
Radoslav
the Telerik team
Browse the vast support resources we have to jumpstart your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
Tags
Grid
Asked by
Manaswinee
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Manaswinee
Top achievements
Rank 1
Radoslav
Telerik team
Share this question
or