Board index » delphi » How do I insert a page break in word through Delphi

How do I insert a page break in word through Delphi

I have a Range selected How do I insert a page break at the endof a range?

Thanks

DJ McNeill

 

Re:How do I insert a page break in word through Delphi


<<DJ McNeill:
I have a Range selected How do I insert a page break at the
endof a range?

Quote

If R is the range:

var
  Direction, BreakType: OleVariant;
..
  Direction := wdCollapseEnd;
  R.Collapse(Direction);
  BreakType := wdPageBreak;
  R.InsertBreak(BreakType);

--
Deborah Pate (TeamB) http://delphi-jedi.org

  Use Borland servers; TeamB don't see posts via ISPs
  http://www.borland.com/newsgroups/genl_faqs.html

Other Threads