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

Filter crashes

4 Answers 71 Views
GridView
This is a migrated thread and some comments may be shown as answers.
ManniAT
Top achievements
Rank 2
ManniAT asked on 17 Mar 2009, 01:21 AM
Hi,

with my first tries on RadGrid I had to learn that there is a problem with the filter.
Reproducing it is easy.
Buil a SQLServer table (let's call it SimpleTable) with two fields - an ID (identity column as PK) and a ntext column.
Enter one record to this table.
Now add a EntityModel (maybe it crashe with other kind of access also - I only tried with EM) and place that table in it.
Add a RadGrid to a WPF Form and in Window_Loaded do
MyEntities mE=new MyEntities();  
var X=from vX in mE.SimpleTable select vX;  
radGridView1.ItemsSource=X
Now run the app - click on the ntext column's filter symbol -- CRASH.

Regards

Manfred

4 Answers, 1 is accepted

Sort by
0
Vlad
Telerik team
answered on 19 Mar 2009, 11:45 AM
Hi Manfred,

Sorry for the late replay!

Indeed you are right. The main reason is the fact that the ntext data type cannot be selected as DISTINCT because it is not comparable.

You can easily resolve this if you call ToList(). Here is an example:

            var X = from vX in mE.SimpleTable select vX;
            RadGridView1.ItemsSource = X.ToList();

Let me know how it goes.

Greetings,
Vlad
the Telerik team


Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
ManniAT
Top achievements
Rank 2
answered on 19 Mar 2009, 01:51 PM
Hi Vlad,

thanks for the workaround.
Anyhow I would say this is a bug since (tell me if I'm wrong) I can expect that a control can deal with such circumstances.

In other words - I bind my data to the control - and do nothing more (no wrong customization or so) - this must not crash the control.
The control could either do what you propessed itself - or at least simply disable the filter in such a situation.
Or - if the request comes at dropdown (I guess this is the fact since the programm crashes at the very moment) it could display a template telling the user - "sorry no filtering availabe" - on restrict the layout to filterable criterias such as "NULL / NOT NULL".

Regards

Manfred
0
Accepted
Vlad
Telerik team
answered on 20 Mar 2009, 05:21 PM
Hi Manfred,

You are right - this is definitely a bug!

We will do our best to provide fix for this in our first service pack.

Regards,
Vlad
the Telerik team

Check out Telerik Trainer , the state of the art learning tool for Telerik products.
0
ManniAT
Top achievements
Rank 2
answered on 20 Mar 2009, 06:21 PM
Thank you Vlad,

I was a bit confused - you did not point out here that it is a bug - a check for my points did also not bring up a bug submission (which not always takes place I know 0 to XXX points) - and so I wanted to clear this.

Once again things are like they should be - a bug happens (normally even with best quality management), you (telerik) provide a workaround - and mark the thing to be fixed.

These workarounds are a thing I'm very happy with.
You are not my one and only supplier - and normally I can be happy if a bug is confirmed and promised for "will be fixed sometimes" :)

And that makes a big difference!

Regards

Manfred
Tags
GridView
Asked by
ManniAT
Top achievements
Rank 2
Answers by
Vlad
Telerik team
ManniAT
Top achievements
Rank 2
Share this question
or