Difference between revisions of "OpenDocument"
From Free Pascal wiki
Jump to navigationJump to searchm |
m |
||
Line 2: | Line 2: | ||
Unit: Lazarus '''lclintf''' | Unit: Lazarus '''lclintf''' | ||
− | |||
− | |||
<syntaxhighlight> | <syntaxhighlight> | ||
function OpenDocument(APath: String): Boolean; | function OpenDocument(APath: String): Boolean; | ||
</syntaxhighlight> | </syntaxhighlight> | ||
+ | |||
+ | Official documentation: [http://lazarus-ccr.sourceforge.net/docs/lcl/lclintf/opendocument.html] | ||
'''opendocument''' opens a document/file with the default viewer/editor registered with the operating system for that file/file extension. E.g. on Windows, the code will use the registry to look up the file association for the extension. | '''opendocument''' opens a document/file with the default viewer/editor registered with the operating system for that file/file extension. E.g. on Windows, the code will use the registry to look up the file association for the extension. |
Revision as of 19:32, 14 December 2012
Unit: Lazarus lclintf
function OpenDocument(APath: String): Boolean;
Official documentation: [1]
opendocument opens a document/file with the default viewer/editor registered with the operating system for that file/file extension. E.g. on Windows, the code will use the registry to look up the file association for the extension.
Example:
uses
...
lclintf
...
OpenDocument('readme.pdf');