KeyView 24.3

# VAPIM_CONVERT

Converts the currently open document to another format, without requiring the user to respond to the SaveAs dialog. To generate the SaveAs dialog box, use the `VAPIMWP_FILE_SAVEAS` message. The `TPVAPIConvert` structure includes two data members, one a target file and the other a format code, which you can set to RTF, text, or HTML.

## Syntax

    #include <kvvapi.h>
    SendMessage( hWndVAPI, VAPIM_CONVERT, 0,
               (LPARAM) (TPVAPIConvert*) lpConvert );

## Arguments

Argument | Description
--- | ---
`hWndVAPI` | The handle of the VAPI window.
`lpConvert` | A pointer to a TPVAPIConvert structure.

## Returns

`SendMessage()` returns `TRUE` if the conversion succeeds.

## Discussion

To make sure that the entire document is opened before the document is converted, open the document with the `bWait` member in the TPVAPIOpenDocumentInfo structure set to `TRUE`. Use the VAPIMWP_CANCONVERT message to determine whether the document has been completely processed and is ready to be converted.

Copyright 2016-2024 Open Text
Version 24.3 | Last updated June 2024

Send documentation feedback

Close

Send documentation feedback

To send feedback using your default email client, open an email window.

Otherwise, send your feedback and the information below to MFI-swpdl.idoldocsfeedback@opentext.com.

We appreciate your feedback!

Product: IDOL KeyView 24.3

Topic Title: VAPIM_CONVERT