Please help me

  • WPRichText1.LoadFromFile()


    Check the helpfile and pdf for more information.
    Hope that helps.

    If you want to increase your chances of a helpful reply, put your problem description in the post title. 'Oh no, please help, oh my' doesn't really give any indication of what your problem is and some people won't even bother to read it. Sorry, but just a peave of mine.

  • Whilst I agree with you about the choice of title I don't think your answer is correct.

    Just calling LoadFromFile will work if the document is simple RTF but most Word documents these days aren't. Some sort of convertor is needed and unfortuately I don't know which.

  • It works ok for me in most cases. Guess I'm lucky :)

    Anyway, there was once a TWPWordConverter you could use. I never needed it, and don't know if it's still available. It was for v4 I think. Don't know if it was ever updated or anything. There's posts about it in the old NG, but not here.

  • Hmmm.... I could have sworn that I posted something in this thread about the WPTools word converter unit not working due to at least two bugs.
    Where did this post go?

    EDIT: Nevermind, Julian deleted my post.

    • Offizieller Beitrag

    Hi Tim,

    You now told me privately you wrote your own word converter unit. I would be interested to see what you made different than I did.

    The demo above works on my system (Word 2003). Since those DLLs depend highly on the version of Word which was installed it is of course possible that they operate differently on another system. Here it would be more helpful to say WHAT problem there is than instead to start bashing this product.

    Since this is a support forum which is intended to be helpful, also for future readers, I reserve the right to edit (or delete) any non helpful post.

    Julian

  • Zitat von wpsupport

    Here it would be more helpful to say WHAT problem there is than instead to start bashing this product.


    I tested the WPTools word converter unit again and now I remember the exact problem. The SaveToFile does not work. The Convert function will clear the Output stream (which actually contains the input) and after that it will generate an access violation. LoadFromFile works fine though. You can read .doc files but you can not write them.

    • Offizieller Beitrag

    >> You can read .doc files but you can not write them.

    Writing was never intended to work since it is not required. You can save to RTF and give it the extension DOC and Word will open it just fine. This way you avoid the problem of possible data loss due to conversion to DOC in an black box DLL. I also think the original question was "somebody knows how to open a documemt from ms word."

  • Zitat von wpsupport

    This way you avoid the problem of possible data loss due to conversion to DOC in an black box DLL.


    I totally agree. We removed the "saving to doc using office text converters" functionality from our application because one of the things that get lost are compressed images (jpg, png, etc.).