How to grouping on ReportItem.DataObject.RawData.Field

2 posts, 1 answers
  1. Dario Concilio
    Dario Concilio avatar
    180 posts
    Member since:
    Apr 2016

    Posted 06 Jul 2016 Link to this post

    Hi to all,

    I have a ObjectDataSource that has a property that return List of object

    I would use this ones to populate a table object, after that Group by a particular field of list.

    But when I try to add group on this table and try to exec report, It show me an error "This field not found in context"


    Ex. I tryed to group on ReportItem.DataObject.RawData.FamilyCode

    Table is in binding with MyMainObject.Rows that returns List<MyDetailedObject>

    MyDetailedObject.FamilyCode exists!


  2. Answer
    Nasko avatar
    1094 posts

    Posted 07 Jul 2016 Link to this post

    Hello Potito,

    The expression ReportItem.DataObject.RawData.FamilyCode is not correct. Depending on the context and how the object is bound to the data item, you need to use the data field directly:

    = Fields.FamilyCode

    or via the ReportItem.DataObject property:

    = ReportItem.DataObject.FamilyCode

    For additional information on the latter approach, please refer to the How to use the ReportItem.DataObject property in expressions help article.

    Telerik by Progress
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top