Skip to Main Content

Oracle Forms

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Using Webutil to create Word Document in DOCX format.

db12345May 17 2019 — edited May 20 2019

Hi All,

I use Jacob/Webutil to create Word documents and it works fine for .rtf and .doc extensions, but when trying to use .docx, the SaveAs invokes the following exception: Incompatible file type and file extension.

Is there a file property or format that needs to be set before invoking the save that will allow it to save successfully.

Below is a snippet of the code being used. This is on Forms 12.2.1.3 running on Windows 7.

ole_application := CLIENT_OLE2.create_obj('Word.Application');

CLIENT_OLE2.set_property( ole_application, 'Visible', 1 );

mydocuments := CLIENT_OLE2.get_obj_property ( ole_application, 'documents' );

mydocument := CLIENT_OLE2.invoke_obj( mydocuments, 'Open', args );

CLIENT_OLE2.destroy_arglist( args );

  ..

args := CLIENT_OLE2.create_arglist;

CLIENT_OLE2.add_arg( args, v_file_name );

CLIENT_OLE2.invoke( mydocument, 'SaveAs', args );

CLIENT_OLE2.destroy_arglist( args );

Regards

Daniel

This post has been answered by db12345 on May 20 2019
Jump to Answer
Comments
Post Details
Added on May 17 2019
6 comments
812 views