NewDocument Method (IApplication)

NewDocument Method (IApplication) | Send Feedback
See Also

Document[out]
  Document

TemplateName
  Path and file name of the template to use for the new document

Creates a new document using the specified template.

# Syntax

Visual Basic |
--- | ---
    Function NewDocument( _
       ByVal TemplateName As System.String _
    ) As Document

C# |
--- | ---
    Document NewDocument(
       System.string TemplateName
    )

JavaScript |
--- | ---
    NewDocument(
       TemplateName : String
    ) : dsDocument

COM native C++ |
--- | ---
    HRESULT NewDocument(
       BSTR TemplateName,
       IDocument** Document
    )

C++ |
--- | ---
    DSRESULT NewDocument(
       const dsString& TemplateName,
       dsDocument** Document
    )

#### Parameters

TemplateName
  Path and file name of the template to use for the new document
Document[out] or Return Value
  Document

# Remarks

If the file specified for TemplateName does not exist, then a new document is not created.

To find out where the DraftSight templates are stored on your computer, interactively create a new document and make note of the path to the DraftSight template files and their file names.

# See Also

####

IApplication Interface
IApplication Members