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
880
using ViewModel property as object data source
posted

Hi,

i am Using Infragistic 14.1 license version. in sample application i was able to use view model property as Object data source. but in my application when i am trying to use my VM property as Object data source in Report ReportDataExplorer-->ObjectdataSource-->VM Namespace.Class(select the class that will return the data)-->Select a method or Property[ here my properties are not available]

how can i make my ViewModel property to be available for choosing as object data source? so they are available in ReportDataExplorer to use in reports. Are they all should be in same namespace?

Namespace.ViewModels : public ObservableCollection<MyType> MyTypes
Namespace.Views : here i am using the ReportViewer in my XAML
Namespace : here i have added myreport.igr file.

one more thing, i am using license version of INfragistics2014.1 (how can i update my profile... it shows 2014.1 trial expires) .. i am not able to log a support ticket.

Regards,
Kamlendra

Parents
  • 14517
    Offline posted

    Hello Kamlendra,

    First off, in order to update your account to the correct support level, you need to register your key to your account. This can be done at https://ko.infragistics.com/my-account/register-product.

    As far as using the collection from your ViewModel in a different namespace, I followed the steps you suggested and was unable to reproduce the behavior you're describing.  I create a WPF application with two folders/ namespaces for the View and the ViewModels, I then added a report to the main application namespace and used a collection from the ViewModel as the data source. I then added the report viewer to my view when running the application, the data was displayed successfully in the report.

    I have attached the sample project I used to test this.  Please test this project on your PC; whether or not it works correctly may help indicate the nature of this problem.

    If the project does not work correctly, this indicates either a problem possibly specific to your environment, or a difference in the DLL versions we are using.  My test was performed using version 14.1.20141.1007 in Infragistics Reporting 14.1.

    If the project does show the product feature working correctly, this indicates a possible problem in the code of your application.  It will help if you can provide a small, isolated sample application that demonstrates the behavior you are seeing.

    Or, if this sample project is not an accurate demonstration of what you're trying to do, please feel free to modify it and send it back, or send a small sample project of your own if you have one.

    Please let me know if I can provide any further assistance.

    Sincerely,

    Valerie

    Developer Support Supervisor - XAML

    Infragistics

    www.infragistics.com/support

     

    WpfMVVMRptEx.zip
Reply Children