GH_DocumentServerAddDocument Method (GH_Document, Boolean) |
Add a new document to the global list. If the document is already registered nothing will happen.
This also applies to a different document which points to the same file path
Namespace:
Grasshopper.Kernel
Assembly:
Grasshopper (in Grasshopper.dll)
Syntaxpublic void AddDocument(
GH_Document document,
out bool success
)
Public Sub AddDocument (
document As GH_Document,
<OutAttribute> ByRef success As Boolean
)
Parameters
- document
- Type: Grasshopper.KernelGH_Document
Document to add. - success
- Type: SystemBoolean
Exceptions| Exception | Condition |
|---|
| ArgumentNullException | Thrown when the document is a null reference. |
| InvalidOperationException | Thrown when the document doesn't have top-level rank. |
See Also