Ticket T139797
Visible to All Users

GridView- Custom Data Binding - The client-side GetSelectedFieldValues method returns a wrong result after the CustomBindingFiltering action

created 11 years ago

We use GridView with custom data binding (http://demos.devexpress.com/MVCxGridViewDemos/DataBinding/AdvancedCustomBinding)) with data filter row. -I explain our propmblem on a simple case:

  1. For examle, we have two rows in database with keys  111, 222 (field ID).
  2. We select all the records and checked all
  3. Filter the records on the field ID enter filter expression: start with "2"
  4. On the screen we see оне checked record with ID 222
  5. However, javascript method GetSelectedRowCount return 2, and GetSelectedFieldValues return two rows. We are expect one record only.

Please, explain us, how get correct checked items from the grid.

Comments (1)
DevExpress Support Team 11 years ago

    Hello,

    We need some additional time to review this information to provide you with a precise answer. We appreciate your patience while we are working on finding a solution to your inquiry.

    Answers approved by DevExpress Support

    created 11 years ago

    Hello Oleg,

    Thank you for your patience. In Custom Data Binding mode, selection results aren't validated on the server since GridView operates only small portions of data. You can use the client-side GetSelectedFilteredRowCount method to return the correct number of filtered rows and use the GetSelectedKeysOnPage  method to return key values visible on the current page. I've recorded a video to illustrate this. We have decided to add this information in our Custom Binding Limitations article: Documentation - Update the Custom Binding Limitations help topic.

    Let me know if you have additional questions.

      Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

      Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.