Hi All,
I am using xamDataPresenter to display my data and change the layout while printing it. I am using Reporting.Report.Sections.Add() method to add my section and also i am using EmbeddedVisualReportSection class to embed my datapresenter.
i.e.
EmbeddedVisualReportSection section = new EmbeddedVisualReportSection(myXamDataPresenter);myReport.Sections.Add(section);
But even if i apply filter in column, this is printing all the rows.
After few research i found that there is this method to get all the filtered rows only as a enumerable datarecord.
i.e. myXamDataPresenter..RecordManager.GetFilteredInDataRecords();
but the problem is, i cant embed the output of this method to EmbeddedVisualReportSection and also cant add it directly to report section as well.
So i was wondering if there is anyway i can just print preview and print only filtered rows??
Any help is appreciated
miztaken
Thank you for your effort. I will try to create a test app and post it here by tomorrow.
Thanksmiztaken
Well, we released v11.1 a few months ago, but still, this should be working in 10.3 as well.
So I tested it with builds 10.3.20103.1003, 10.3.20103.2164 and 10.3.20103.2250(the latest service release), but I couldn't reproduce the problem.
I'm using 10.3 version. Isn't that the latest?
That's very strange. I tried the code you posted and it seems to be working fine for me.
Which NetAdvantage version are you using? May I suggest you download the latest Service Release and test this again. If the problem persists, please, provide us with a small sample application so we can investigate further.
Thanks
Hi Galina,
Thanks for the reply. I am still unable to get the desired output.
I have coded like this:-
xamPresenter.DataSource = dtDepositListing.DefaultView;TabularReportView view = new TabularReportView();view.ExcludeRecordFilters = false;xamPresenter.ReportView = view;section = new EmbeddedVisualReportSection(xamPresenter);
Report reportobj=new Report();reportobj.Sections.Add(section);xamReportPreview.GeneratePreview(reportobj,false,false);DocumentViewer docv=xamReportPreview.DocumentViewer;docv.Focus();
Am i doing something wrong? pls let know.
Also, I have solved this problem using two xamdatapresenter. Transferring filtered IN rows from one xampresenter to another but i dont think this is a good solution as transfer time will increase with more records. So i want to have a decent solution.
let me know