InsertTextBox in header

  • Hello,
    when I insert a text in the header, the content is not displayed:

    Code
    rtf.ActiveText := rtf.HeaderFooter.Get(wpIsHeader, wpraOnFirstPage);
    obj := rtf.TextObjects.InsertTextBox(1000, 1000, block);
    obj.Mode := [wpobjDrawAsText];
    block.RtfText.AsString := 'Hello World';

    If I save the document, the <txtobj> is stored under
    <element kind="Header" Range="OnFirstPage">

    If I use
    rtf.ActiveText := rtf.BodyText;
    its working

    Mfg, Kai Brendel

  • Hello,

    for headers:

    Code
    rtf.ActiveText := rtf.HeaderFooter.Get(wpIsHeader, wpraOnFirstPage);


    your update works, in first tests, but not for footers....

    [Blockierte Grafik: http://pixandmore.com/footer.png]
    hmmm, image is in preview mode visible, not in the post???

    Code
    rtf.ActiveText := rtf.HeaderFooter.Get(wpIsFooter, wpraOnFirstPage);

    In both ways, the WPT-File is saved and loaded corretly, but the textbox is for footers not accessible!

    PS: The same for images...


    Mfg, Kai Brendel