reading out field content

  • Hello everybody,

    I have to set some fields into a document, save it and read out the field content later. No database, no nothing. I can create the fields, fill them out, save them, read them out - fine. But it's only working as long as there is no hardreturn inside the content of the field. Everything behind a hardreturn will not be read out. I tried this way:

    WPR1.InputEditField('Orientierungssatz','Orientierungssatz',false);
    wpr1.MergeEnumFields('Orientierungssatz');

    procedure TForm1.test1Click(Sender: TObject);
    begin
    wpr1.MergeEnumFields('Orientierungssatz');
    end;

    procedure TForm1.WPR1MailMergeGetText(Sender: TObject;
    const inspname: String; const Contents: TWPMMInsertTextContents);
    begin
    showmessage(contents.OldText);
    end;


    and I tried to read out using readfieldtext too, but the result was the same: everything but cut off after a hardreturn.


    Meanwhile I'm in quite *desperate* need for a solution - can anybody help me?

    Thanks in advance

    Ruediger

  • Zitat von wpsupport

    Use InputEditField to create the field. This will create an start + endcode and so read back of paragraph breaks is possible.

    Julian

    Ähm Julian: I think that I *do* use inputeditfield to create the field! Please look at my example - or did I completely missunderstood something?

    Thanks for your reply
    Ruediger