TDBWPRichText and Addict4

  • Issue with WPTools 7 and Addict 4. I checked this forum for posts about
    WPTools 6 and thought this was fixed, but I am still having this problem...

    Using TDBWPRichText and Addict4, running the spell check and then clicking in the text box will revert to the pre spell check version. This happens even if Changing is called before the spell check. For example:

    CommentsBox.Changing;
    CheckWPTools (AddictSpell1, CommentsBox, ctSmart);
    CommentsBox.ChangeApplied;

    Everything works properly with TWPRichText, but not with TDBWPRichText.

    Thanks for your help with this!

  • Thank you. I verified that dataset is in edit mode, and also tried explicitly calling Edit again, but it still doesn't work.

    StudyTable.Edit;
    CommentsBox.Changing;
    CheckWPTools (AddictSpell1, CommentsBox, ctSmart);
    CommentsBox.ChangeApplied;

    After the spell check clicking in the CommentsBox reverts the text to what it was before the spell check.

    What else can I try?

  • Thanks again. I think you are right about the underlying dataset. The TDBWPRichText component is connected to a VARCHAR(500) rather than a memo blob. And I just noticed that it won't even save RTF at all, it all gets reverted to plain text. That is OK, I have lots of installed customers and can't change the DB, so they will just have to do without rich text in that field.

    I worked around the spell check reversion by reading the component's contents and setting the DB field after the check like this:

    CheckWPTools (AddictSpell1, CommentsBox, ctSmart);
    StudyTable['Sonographer Comments']:=CommentsBox.text;

    That works. Just curious why it won't work with a VARCHAR, but that's OK. Thanks much!