Determines whether the specified image, document, or vector file can be loaded as a DOC file.
#include "l_bitmap.h"
L_LTFIL_API L_INT L_CanLoadDoc(pszFile, pbSupported, pLoadOptions, pFileInfo)
Character string containing the name of the image file to load.
Pointer to a variable to be updated. TRUE if the specified image, document, or vector file can be loaded as SVG; otherwise, FALSE.
Pointer to optional extended load options. Pass NULL to use the default load options.
Pointer to optional FILEINFO structure. Pass NULL if you do not know or do not need the file information.
Value | Meaning |
---|---|
SUCCESS | The function was successful. |
< 1 | An error occurred. Refer to Return Codes. |
Use this function to determine whether the specified image, document, or vector file supports being loaded and converted on-the-fly to a document file format using L_LoadDoc. In the future, this function could be used to check if conversion to several document formats is possible. Right now, the only supported output format is PDF. The following conditions must be met in order to load one or more pages from a file and convert them to PDF:
Condition | Description |
---|---|
The file format is a document file format | Any of the document file formats (AFP, DOC/DOCX, PPT/PPTX, XLS/XLSX/XLSB, TXT, PTK, etc.), supported by LEADTOOLS. These formats will set the FILEINFO.bIsDocFile member to TRUE when calling L_FileInfo. |
In addition to LTFIL and LTKRN, the following additional DLLs/assemblies are required to support loading as PDF:
DLL | Description |
---|---|
LTDIS | Display functions. |
LTDRW | Drawing engine. |
LTDOCWRT | Document writer engine. |
LTDOCWRTEMF | Document Writer Emf engine. |
LTDOCWRTPDF | Document Writer PDF engine. |
LTDOCWrtTtf | Document Writer True Type font engine. |
LTIMGCOR | Core Image Processing functions. |
LTSVG | Scalable Vector Graphics File Format. |
Note: More options are available in the LOADFILEOPTION structure.
Support for loading as PDF is only available in the Document and Medical Imaging toolkits.
Note: You should never pass an uninitialized FILEINFO structure to this function.
Win32, x64, Linux.
For an example, refer to L_LoadDoc.
Help Collections
Raster .NET | C API | C++ Class Library | HTML5 JavaScript
Document .NET | C API | C++ Class Library | HTML5 JavaScript
Medical .NET | C API | C++ Class Library | HTML5 JavaScript
Medical Web Viewer .NET
Multimedia
Direct Show .NET | C API | Filters
Media Foundation .NET | C API | Transforms
Supported Platforms
.NET, Java, Android, and iOS/macOS Assemblies
Imaging, Medical, and Document
C API/C++ Class Libraries
Imaging, Medical, and Document
HTML5 JavaScript Libraries
Imaging, Medical, and Document