Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
20
Hide/Display column in Infragistic report
posted

Hi,

I am new to Infragistic controls. I want to create a dynamic report such that, the columns dispalyed in the report are dynamic.

I have a XamDataGrid and a combobox in a WPF window. The XamDataGrid get loaded with two different classes according to the selection of the combobox. There is a button, onClick of which a new window opens which displays the data from the grid to the report. The data are being passed as a collecrtion of two different classes and the same is used to bind to reports, but only one of the two class report is generated and other does not, where as the other have data. What I need to know is, is it possible to send data as one single class and display only the columns in the report which have data, and hide the rest?

Thanks in Advance! Ruchi

Parents
No Data
Reply
  • 380
    Verified Answer
    posted

    Hi Ruchi,

    The scenario you need is not supported out of the box in NetAdvantage Reporting yet.

    However, if you know the class the data will have before rendering, you could create two separate reports that handle each of the classes, and decide at runtime which report to render.

    One possible mechanism to reach this behavior is using a custom uri resolver. You can read more about this on the topic “How to Customize Report Uri Resolution”: http://ko.infragistics.com/help/topic/B7E5286A-36E7-42E7-B520-E5F205936EC5

    Another option would be creating a single report that has two tables, one for each possible datasource, and bind the visibility of the tables to a parameter that tells which one should be displayed.

    You can read more about this on the topic “How to Use Conditional Formatting”: http://ko.infragistics.com/help/topic/73608305-6896-4A19-A2F2-B1C770ACF0A7

    Please let us know if any of these options would work for you.

    Regards,

    Luis

Children