BookSetPageText
Sets the text content of a specific page in the currently open book.
The book must be opened beforehand (e.g. via UseObject or UseType). If no book is open, the method logs a warning and does nothing. If Page is 0 or exceeds the book’s page count, the method logs a warning — page numbering starts from 1.
To set the entire book text at once (with automatic page splitting), use BookSetText.
Устанавливает текстовое содержимое конкретной страницы текущей открытой книги.
Книга должна быть предварительно открыта (например, через UseObject или UseType). Если книга не открыта, метод выводит предупреждение и ничего не делает. Если Page равен 0 или превышает количество страниц книги, метод выводит предупреждение — нумерация страниц начинается с 1.
Для установки всего текста книги сразу (с автоматическим разбиением по страницам) используйте BookSetText.
procedure BookSetPageText(Page: Word; Text: String);
Parameters:
- Page — page number (1-based).
- Text — text content for the page.
def BookSetPageText(Page: int, Text: str) -> None: ...
begin
UseObject(FindItem);
Wait(1000);
BookSetPageText(1, 'Chapter 1: The Beginning');
BookSetPageText(2, 'It was a dark and stormy night...');
end.
UseObject(FindItem())
Wait(1000)
BookSetPageText(1, 'Chapter 1: The Beginning')
BookSetPageText(2, 'It was a dark and stormy night...')