SQL Object
 
Syntax
 
SQL.CreateRTFDocument(Sjabloon, SaveAs, Contents, [Append])
 
Description
Opens a Microsoft Word template (.dot) or document (.doc) or existing Richt Text Formatted file (RTF) and saves it as a new RTF document, returning the contents in a parameter.
 
Returns value TRUE on success, FALSE otherwise.
 
Parameter
Description
Sjabloon
String, contains the full path and file name of the source document. For sources
.DOC, .DOT (MS-Word) or .RTF may be used.
SaveAs
The name, including path, of the new RTF document to be created.
Contents
A string representing the contents (including RTF codes)
of the new document.
Append
Optional. If TRUE, an existing document specified under SaveAs is expanded with a new page based on Template.
 
See Also
Example
Sub Main()
 
    Dim Inhoud As String
 
    Debug.Print CreateRTFDocument("c:\mijnsjabloon.dot", _
                                  "c:\nieuwdocument.rtf", Inhoud)
 
    Debug.Print Inhoud
 
End Sub