I want to Insert at the end of a document a pagebreak. I found a method named setPageBreak but it did not work. It looks like a part of a package for a specific programming language. The "StarOffice Programmer’s Tutorial" told me a pagebreak is a property of a paragraph. So I tried to get the properties. Any testwhith the cursor object I tried failed.
Now I have 3 problems:
How to get the last paragraph
How to get the property values of the last paragraph (I want to remove a pagebreak too)
How to set the breakType with Delphi
The list of breakTypes lists only textual types, but no values I can set from Delphi.
Who can help??
Greetings
Peter
Last edited by Peter18 on Mon Nov 14, 2011 11:24 am, edited 1 time in total.
OpenOffice 4.1 on Windows 10 and Linux Mint
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.
OpenOffice 4.1 on Windows 10 and Linux Mint
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.
I have not seen any enum which has specified value in IDL Reference.
If an IDL defined as follows, autodoc generates "BAR = 10," in the description of BAR element.
#ifndef __Myenum__
#define __Myenum__
published enum Myenum
{
NONE,
FOO,
BAR = 10,
HOGE,
};
#endif
Please, edit this thread's initial post and add "[Solved]" to the subject line if your problem has been solved.
Apache OpenOffice 4-dev on Xubuntu 14.04
I'm sorry I was unclear. The values are not shown on the linked page, just the order of the enum list. I deduced the value from that order. I got the values for PAGE_BEFORE and PAGE_AFTER just by counting down the list, starting with zero. I read somewhere that enums are always listed in the order of their value. I don't recommend using those values normally, but since I don't know how to get Delphi to recognize the value of com.sun.star.style.BreakType.PAGE_BEFORE, I mentioned this trick.
OpenOffice 4.1 on Windows 10 and Linux Mint
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.
I'm sorry I could not look at the board for some days.
Hello FJCC,
thank you for your answer. "com.sun.star.style.BreakType.PAGE_BEFORE" did not work, but I declared a const and it worked. I think you are right, the code is the index of enumeration.
Hello hanya,
thank you too for your answer.
hanya wrote:I have not seen any enum which has specified value in IDL Reference.
I saw a enumeration with corresponding number, but I don't remember in what context. If I find it again I'll give you the link,
Please, edit this thread's initial post and add "[Solved]" to the subject line if your problem has been solved.
Apache OpenOffice 4-dev on Xubuntu 14.04
Where do I find these breaks in a given document? I mean, when I iterate over all paragraphs how do I detect that there is such a page break in the text?
Mac 10.14 using LO 7.2.0.2, Gentoo Linux using LO 7.2.3.2 headless.
the first print statement returns the value zero and the second one returns four. The numeric values are assigned according to the order here.. The first paragraph in my document has BreakType=NONE and the second has BreakType=PAGE_BEFORE.
OpenOffice 4.1 on Windows 10 and Linux Mint
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.
A soft pagebreak is created by Writer itself as text reaches the end of one page and starts on another. The BreakType of a paragraph is inserted manually by the user.
OpenOffice 4.1 on Windows 10 and Linux Mint
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.