Syntax
| Encode64_File(FilePath)
| ||||
|---|---|---|---|---|---|
Description
| Return a base64-encoded string representing the binary contents of the specified file. This function reads the file directly into a native binary buffer and performs the base64 encoding without intermediate string conversion, making it significantly faster than reading a file into a string variable and passing it to Encode64. This is particularly beneficial for large binary files such as images, PDFs and other documents. Internally, the function uses the Chilkat BinData component for high-performance native encoding. If the file cannot be read (e.g. the file does not exist or is locked), an empty string is returned.
| ||||
See Also
| |||||
Example
| Sub Main |