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

Excel Like Filtering - using Webservice context is NULL

9 Answers 79 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Srikrishna
Top achievements
Rank 1
Srikrishna asked on 12 Apr 2016, 07:47 PM

W.r.t to Excel like filtering in radgrid. I am trying to call a webservice using -

ADMIN: Code removed upon OP request.

Requirement : To use Webservice , I have 40 columns so planning to send Column name as a context to WS method and reuse the select query for all..
eg)

 

ADMIN: Code removed upon OP request.

9 Answers, 1 is accepted

Sort by
0
Maria Ilieva
Telerik team
answered on 15 Apr 2016, 01:01 PM
Hi,

Note that using WebMethod as you are trying to achieve in your code would not work in this case. You should use WebService as shown in the online demo below:
http://demos.telerik.com/aspnet-ajax/listbox/examples/loadondemand/wcf/defaultcs.aspx

I hope this helps.

Regards,
Maria Ilieva
Telerik
Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.
0
Srikrishna
Top achievements
Rank 1
answered on 15 Apr 2016, 08:10 PM

Thank you for your reply. The example you provided will involve much changes in my side as I have 40 columns and I would like to avoid using radcombo or listbox .. instead of my current gridboundcolumn. That's fine we settled with using multiple methods to achive this scenario.

 

I have found one more issue in Excel like filtering grid. When select few checkbox and click 'filter' it works fine. But once user tries to reopen the same column and click 'Clear Filter' button . It is not unchecking the checkbox selected by user before. I see that your online demo is working fine but I am not able to replicate that clearing in my side.

 

Question 1: Is there a way for me to Handle the 'ClearFilter' event in codebehind (or) client side .

Question 2 : I only want to clear the selected column filter not other remaining columns.

Question 3 : When I click 'Filter' button - radgrid filters but I don't get to see the loading image. Which shows up on other operations.

 

Please find the code .. Removed few lines . Please help. Using Vs 2015 enterprise , ,net 4.5.01055

Telerik : v4.0.30319 ,  version : 2015.3.1111.45 , Telerik UI for ASP.NET AJAX

 

 

ADMIN: Code removed upon OP request.

 

0
Maria Ilieva
Telerik team
answered on 20 Apr 2016, 02:07 PM
Hi Srikrishna,

The mentioned issue was a problem in older version of the controls and this behavior is already fixed in the  latest official release. I would suggest you to update your application to the latest version and see how it goes.


Regards,
Maria Ilieva
Telerik
Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.
0
Srikrishna
Top achievements
Rank 1
answered on 20 Apr 2016, 02:18 PM

Hi ,

   Sorry not sure about your reply , as I had the following 3 questions in it.

Question 1: Is there a way for me to Handle the 'ClearFilter' event in codebehind (or) client side .
Question 2 : I only want to clear the selected column filter not other remaining columns.
Question 3 : When I click 'Filter' button - radgrid filters but I don't get to see the loading image. Which shows up on other operations.

 

You mean to say that Question 2 -- will be resolved with latest version ?

Can you please suggest something on Question 1 and Question 3?

 

Thanks

 

0
Maria Ilieva
Telerik team
answered on 25 Apr 2016, 12:41 PM
Hi Srikrishna,

1. The ClearFilter method fires OnCommand event and OnUseraction event that can be handeled.
2. If you need to clear the filter for specific column you could simply filter without parameter to achieve this requirement.
3. The LoadingPanel will appear when regular Ajax request is performed and when a service is called you should call it manually as shown below:
http://docs.telerik.com/devtools/aspnet-ajax/controls/ajaxloadingpanel/how-to/show-and-hide-ajaxloadingpanel-explicitly






Regards,
Maria Ilieva
Telerik
Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.
0
Srikrishna
Top achievements
Rank 1
answered on 15 Jun 2016, 03:17 AM

HI MARIA,

   Thank you for the options.

   Could you please give an sample code to using - ' The ClearFilter method fires OnCommand event and OnUseraction event that can be handeled.'

   I have 10 columns in my radgrid , when I click clear filter button --- I don't know how to get the current column & how to uncheck the checkboxs that I selected earlier to filter upon ... I mean I want to perform a nofilter operation on click on clearfilter.

 

   appreciate if you could provide a sample for 1 and 2 options you provided.

thanks

krishna

 

0
Maria Ilieva
Telerik team
answered on 17 Jun 2016, 01:50 PM
Hello,

You can simply handle the server OnCommand event with Filter command name as when "Clear Filter" button is clicked a filter command with empty filter function, value and expression fires.

Regards,
Maria Ilieva
Telerik
Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.
0
Srikrishna
Top achievements
Rank 1
answered on 19 Jan 2017, 05:34 PM

Please delete the following post from me ... as it contains some information that I should have removed before posting..

 

http://www.telerik.com/forums/excel-like-filtering---using-webservice-context-is-null#ho0lv6aTg0-ZZH_ZJqXfEg

 

0
Accepted
Marin Bratanov
Telerik team
answered on 19 Jan 2017, 05:46 PM

Hi Krishna,

I removed the code snippets. I left the discussion itself in case someone else finds it useful.

Regards,

Marin Bratanov
Telerik by Progress
Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Tags
Grid
Asked by
Srikrishna
Top achievements
Rank 1
Answers by
Maria Ilieva
Telerik team
Srikrishna
Top achievements
Rank 1
Marin Bratanov
Telerik team
Share this question
or