File Content Extraction 25.1
Viewing SDK Programming Guide

# Determine the Document Format

To determine a document format

1. Open the document. See Open and View a Document.

   To get format information without viewing the document, set the `VAPIDF_FLAGS_OPEN_VAPI_ONLY` flag in the `nFlags` member of the `TPVAPIOpenDocumentInfo` structure.

   To quickly determine a document's format, regardless of whether the document is supported for viewing, set the `VAPIDF_FLAGS_OPEN_FORMAT_ONLY` flag in the `nFlags` member of the `TPVAPIOpenDocumentInfo` structure. Only the `VAPIM_INIT` message with the `VAPIMWP_INIT_GETDOCFORMAT` parameter is supported when opening a document with the `VAPIDF_OPEN_FORMAT_ONLY` flag enabled.

2. Use the VAPIMWP_INIT_GETDOCFORMAT parameter of the `VAPIM_INIT` message to get the document format of the currently opened document.

3. Use the VAPIMWP_INIT_GETDOCCLASS parameter of the `VAPIM_INIT` message to get the general class to which the currently opened document belongs.

Copyright 2016-2024 Open Text
Version 25.1 | Last updated January 2025

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: File Content Extraction 25.1

Topic Title: Determine the Document Format