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

FilterExpressions - Not available after update?

1 Answer 47 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Terry
Top achievements
Rank 1
Terry asked on 12 Aug 2014, 01:47 PM
Hello,

I've recently updated to the latest version of WinConrols UI (2014.2.715.40) after realising that MasterGridViewTemplate is now MasterTemplate
It now reports that filterexpressions properties are no longer valid.

What's the best way to update the code below? It essentially saves the filters to a sql table.
Thanks

Dim feCollection As FilterExpression() = New FilterExpression(grid.MasterTemplate.FilterExpressions.Count) {}
        Dim i As Integer = 0
        While i < grid.MasterTemplate.FilterExpressions.Count
            InsertJobLibraryFilterValues(grid.Name, grid.MasterTemplate.FilterExpressions(i).PropertyName, grid.MasterTemplate.FilterExpressions(i).Operator, grid.MasterTemplate.FilterExpressions(i).Value, iFilterGroupID)
            i = i + 1
        End While

        Return feCollection




1 Answer, 1 is accepted

Sort by
0
Stefan
Telerik team
answered on 13 Aug 2014, 06:50 AM
Hi Terry,

Thank you for writing.

In Q2 2014 we have removed a lot of obsolete code from our codebase, including the mentioned properties. Information about the removed members and what to use instead is available in our Release Notes

As to the case at hand, you code should look something like this:
Dim feCollection As FilterDescriptor() = New FilterDescriptor(radGridView1.MasterTemplate.FilterDescriptors.Count - 1) {}
Dim i As Integer = 0
While i < radGridView1.MasterTemplate.FilterDescriptors.Count
    InsertJobLibraryFilterValues(radGridView1.Name, radGridView1.MasterTemplate.FilterDescriptors(i).PropertyName, radGridView1.MasterTemplate.FilterDescriptors(i).[Operator], radGridView1.MasterTemplate.FilterDescriptors(i).Value, iFilterGroupID)
    i = i + 1
End While
 
Return feCollection

I hope this helps.

Regards,
Stefan
Telerik
 
Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
 
Tags
General Discussions
Asked by
Terry
Top achievements
Rank 1
Answers by
Stefan
Telerik team
Share this question
or