Home All Groups Group Topic Archive Search About

Creating WordPerfect document from VB

Author
22 Sep 2005 4:59 PM
Dave
I have to create a WordPerfect document from a VB6 program. Nothing really
difficult, just dump some text into it in multiple lines, save it and exit.

Anybody done this before?

Author
22 Sep 2005 6:28 PM
Ken Halter
"Dave" <D***@discussions.microsoft.com> wrote in message
news:BCFF867A-000F-4528-8C9C-D9B0EAFDB559@microsoft.com...
>I have to create a WordPerfect document from a VB6 program. Nothing really
> difficult, just dump some text into it in multiple lines, save it and
> exit.
>
> Anybody done this before?

It doesn't look like very many have tried <g> Here's an article that may
help.... if you can figure out what the strange characters are (and remove
that hard coded file number <g>)

Automate WordPerfect from VB (Article)
http://www.freevbcode.com/ShowCode.Asp?ID=4021

--
Ken Halter - MS-MVP-VB - http://www.vbsight.com
DLL Hell problems? Try ComGuard - http://www.vbsight.com/ComGuard.htm
Please keep all discussions in the groups..
Author
22 Sep 2005 6:56 PM
Jim Edgar
"Dave" <D***@discussions.microsoft.com> wrote in message
news:BCFF867A-000F-4528-8C9C-D9B0EAFDB559@microsoft.com...
> I have to create a WordPerfect document from a VB6 program. Nothing really
> difficult, just dump some text into it in multiple lines, save it and
exit.
>
> Anybody done this before?
>
>

I've done it with Word but not WordPerfect.  Is it possible to use a
RichText control and just save the rtf text to a file with an rtf extension?
I assume WordPerfect can open a simple rtf file so your app will work with
either product.

Jim Edgar
Author
23 Sep 2005 12:02 PM
Matt Williamson
Dave-

I haven't worked with WP since version 9 and at that time they were porting
the wordperfect macro library to a VBA class, but it wasn't callable outside
the program. I would think that 2-3 versions later they would have that
available now. If so, it would be similar to using Word automation. If not,
I think your best bet would be to create plain text files and then write a
Wordperfect macro to loop through them and save them in WP format.

HTH

Matt

Show quoteHide quote
"Dave" <D***@discussions.microsoft.com> wrote in message
news:BCFF867A-000F-4528-8C9C-D9B0EAFDB559@microsoft.com...
>I have to create a WordPerfect document from a VB6 program. Nothing really
> difficult, just dump some text into it in multiple lines, save it and
> exit.
>
> Anybody done this before?
>
>