StiWpfViewerControl Report Binding

Stimulsoft Reports.WPF discussion
Post Reply
aferguson
Posts: 7
Joined: Fri Nov 20, 2009 2:39 pm

StiWpfViewerControl Report Binding

Post by aferguson »

Hello,

If this question has been asked already, I apologize; I couldn't find it in the search.

Basically what I'm trying to do is bind an StiReport to the Report property of an StiWpfViewerControl, and I'm not having any luck. It tells me that Report is not a dependency property, and so binding is unavailable. As I'm using MVVM, I would like to avoid directly setting a property on the StiWpfViewerControl itself (in the View), and instead simply change the value of a bound property in the ViewModel. Am I missing something or some other property, or is this just not possible? Any help would be most appreciated.

Thanks,
Adam
Andrew
Posts: 4108
Joined: Fri Jun 09, 2006 3:58 am

StiWpfViewerControl Report Binding

Post by Andrew »

Hello,

The Report property in StiWpfViewerControl is described as a simple property but not the DependencyProperty:

private StiReport report;
public StiReport Report
{
get
{
return report;
}
set
{
.....
report = value;
}
}

Therefore, Binding will not work. You need to use the following code viewer.Report = report;

Thank you.
aferguson
Posts: 7
Joined: Fri Nov 20, 2009 2:39 pm

StiWpfViewerControl Report Binding

Post by aferguson »

That's what I was afraid of. Having to set the report object on the view directly isn't really a desirable way to handle it when building the report object on the viewmodel. Is there any chance that in the future this will become a dependency property to support binding? In any case, thanks for the clarification.
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

StiWpfViewerControl Report Binding

Post by Alex K. »

Hello,

We made some improvements in that direction. Please check the prerelease build on next week.

Thank you.
Vynoslivost
Posts: 1
Joined: Fri Jan 07, 2011 1:22 pm
Location: United States

StiWpfViewerControl Report Binding

Post by Vynoslivost »

Has there been any progress on this? I am working with your 2011.1 release.
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

StiWpfViewerControl Report Binding

Post by Alex K. »

Hello,

We made some improvements and checks in that direction.
Please check the latest prerelease build when it will be available.

Thank you.
Post Reply