StiWpfViewerControl in Xaml

Stimulsoft Reports.WPF discussion
Post Reply
anuv
Posts: 4
Joined: Thu Feb 01, 2018 7:06 am

StiWpfViewerControl in Xaml

Post by anuv »

Hi

I am pretty new Stimulsoft. I was wondering how to use the StiWpfViewerControl in XAML. I tried following, but it doesn't seem to work (could not find StiWpfViewerControl' error).

xmlns:sti="clr-namespace:Stimulsoft.Report.Viewer;assembly=Stimulsoft.Report"

<sti:StiWpfViewerControl x:Name="viewerControl"/>

Could someone please guide me ?

Thanks
Anu
anuv
Posts: 4
Joined: Thu Feb 01, 2018 7:06 am

Re: StiWpfViewerControl in Xaml

Post by anuv »

Managed to figure it myself. But am still getting the Report empty.

This is what i am doing currently

<wpfViewer:StiWpfViewerControl Report="{Binding CurrentReport}" x:Name="viewerControl"/>

private Stimulsoft.Report.StiReport _CurrentReport;

public Stimulsoft.Report.StiReport CurrentReport
{
get { return _CurrentReport; }
set
{
_CurrentReport = value;
NotifyOfPropertyChange(nameof(CurrentReport));
}
}


this.CurrentReport = _Report;
this.CurrentReport.RenderWithWpf();
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

Re: StiWpfViewerControl in Xaml

Post by Alex K. »

Hello,

Please check samples at the following link:
https://github.com/stimulsoft/Samples-WPF-CSharp

Thank you.
Post Reply