Page break not work when exporting Word2007 Document.

Stimulsoft Reports.NET discussion
Post Reply
ethan.shi
Posts: 24
Joined: Mon Apr 22, 2013 2:53 am

Page break not work when exporting Word2007 Document.

Post by ethan.shi »

Hi,

I set NewPageAfter = true in my mrt file,
but it seems it does not work in the exported Word2007 Document.
However it works in the Pdf Document.

by the way , here is the code to export document.

Code: Select all

                StiWord2007ExportService service1 = new StiWord2007ExportService();
                StiWord2007ExportSettings settings = new StiWord2007ExportSettings();
                settings.UsePageHeadersAndFooters = true;
                FileStream fs1= File.Create(strOutputFilePath + ".service.docx");
                service1.ExportWord(report, fs1, settings);
                fs1.Close();
test.mrt
(26.34 KiB) Downloaded 223 times
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: Page break not work when exporting Word2007 Document.

Post by HighAley »

Hello.

You should either set the UsePageHeadersAndFooters export setting to false or
5.6.2.1.1 Table Modes of User Manual wrote: it is possible to export a separate sheets of a template to separate sections of the document with
the headers/footers. To do this, use the ExcelSheet property. in this case all pages of a report with the
same value of the ExcelSheet property are combined in groups, then each group is exported as a
separate section of the document with its headers/footers. By default, this property is not filled, and the
report is exported as a single partition.
Thank you.
ethan.shi
Posts: 24
Joined: Mon Apr 22, 2013 2:53 am

Re: Page break not work when exporting Word2007 Document.

Post by ethan.shi »

Aleksey Andreyanov wrote:Hello.

You should either set the UsePageHeadersAndFooters export setting to false or
5.6.2.1.1 Table Modes of User Manual wrote: it is possible to export a separate sheets of a template to separate sections of the document with
the headers/footers. To do this, use the ExcelSheet property. in this case all pages of a report with the
same value of the ExcelSheet property are combined in groups, then each group is exported as a
separate section of the document with its headers/footers. By default, this property is not filled, and the
report is exported as a single partition.
Thank you.
Hi, Aleksey

"5.6.2.1.1 Table Modes of User Manual" is about RTF formt, but I need Word2007 Format(/.docx),

Does the ExcelSheet property works in docx?
ethan.shi
Posts: 24
Joined: Mon Apr 22, 2013 2:53 am

Re: Page break not work when exporting Word2007 Document.

Post by ethan.shi »

ethan.shi wrote:
Aleksey Andreyanov wrote:Hello.

You should either set the UsePageHeadersAndFooters export setting to false or
5.6.2.1.1 Table Modes of User Manual wrote: it is possible to export a separate sheets of a template to separate sections of the document with
the headers/footers. To do this, use the ExcelSheet property. in this case all pages of a report with the
same value of the ExcelSheet property are combined in groups, then each group is exported as a
separate section of the document with its headers/footers. By default, this property is not filled, and the
report is exported as a single partition.
Thank you.
Hi, Aleksey

"5.6.2.1.1 Table Modes of User Manual" is about RTF formt, but I need Word2007 Format(/.docx),

Does the ExcelSheet property works in docx?

Hi, Aleksey

It works! Thank you!
Andrew
Posts: 4109
Joined: Fri Jun 09, 2006 3:58 am

Re: Page break not work when exporting Word2007 Document.

Post by Andrew »

Great!

Have a nice day!
Post Reply