AcadDocument
AcadDocument Class
Supported Platforms: Windows only
Object Inheritance
Members
These members are part of this object:
- CopyObjects()
VARIANT CopyObjects([in] VARIANT Objects, [in Owner, optional] VARIANT,[in, out] Pointer Type IdPairs)
Duplicates multiple objects.
- HandleToObject()
IDispatch* HandleToObject([in] BSTR Handle)
Returns the object that corresponds with a specified handle.
- ObjectIdToObject()
IDispatch* ObjectIdToObject(LONG_PTRShort ObjectID)
Returns the object that corresponds with a specified object ID.
- Open()
IAcadDocument* Open([in] BSTR FullName, [in, optional] VARIANT Password)
Opens an existing drawing file (DWG) and makes it the active document
- AuditInfo()
Void AuditInfo([in] Boolean FixErr)
Evaluates the integrity of the drawing
- Import()
IDispatch* Import([in] BSTR FileName, [in] VARIANT InsertionPoint, [in] Double ScaleFactor)
Imports a drawing file in SAT, EPS, DXF, or WMF format
- Export()
Void Export([in] BSTR FileName, [in] BSTR Extension, [in] Pointer Type SelectionSet)
Exports the Argon drawing to a WMF, SAT, EPS, DXF, or BMP format
- New()
IAcadDocument* New([in] BSTR TemplateFileName)
Creates a new document in SDI mode
- Save()
Void Save( )
Saves the document or menu group
- SaveAs()
Void SaveAs([in] BSTR FullFileName, [in SaveAsType, optional] VARIANT,[in, optional] VARIANT vSecurityParams)
Saves the document or menu group to a specified file
- Wblock()
Void Wblock([in] BSTR FileName, [in] Pointer Type SelectionSet)
Writes out the given selection set as a new drawing file
- PurgeAll()
Void PurgeAll( )
Removes unused named references such as unused Symbols or Layers from the document
- GetVariable()
VARIANT GetVariable([in] BSTR Name)
Gets the current setting of a system variable
- SetVariable()
Void SetVariable([in] BSTR Name, [in] VARIANT Value)
Sets the value of a system variable
- LoadShapeFile()
Void LoadShapeFile([in] BSTR FullName)
Loads a shape file (SHX)
- Regen()
Void Regen(AcRegenTypeShort WhichViewports)
Regenerates the entire drawing and recomputes the screen coordinates and view resolution for all objects
- Activate()
Void Activate( )
Makes the specified drawing active
- Close()
Void Close([in SaveChanges, optional] VARIANT,[in, optional] VARIANT FileName)
Closes the specified drawing, or all open drawings
- SendCommand()
Void SendCommand([in] BSTR Command)
Sends a command string from a VB or VBA application to the document for processing
- StartUndoMark()
Void StartUndoMark( )
Marks the beginning of a block of operations
- EndUndoMark()
Void EndUndoMark( )
Marks the end of a block of operations
- StartTransaction()
Void StartTransaction( )
Starts a new transaction of this document
- EndTransaction()
Void EndTransaction( )
Ends the current transaction associated with this document
- AbortTransaction()
Void AbortTransaction( )
Aborts the current transaction associated with this document
- NumActiveTransactions()
Int NumActiveTransactions( )
Returns the number of active transactions associated with this document.
- ModelSpace [ReadOnly]
IAcadModelSpace* ModelSpace( )
Returns the ModelSpace collection for a document.
- PaperSpace [ReadOnly]
IAcadPaperSpace* PaperSpace( )
Returns the PaperSpace collection for a document.
- Blocks [ReadOnly]
IAcadBlocks* Blocks( )
Returns the Blocks collection for a document.
- Groups [ReadOnly]
IAcadGroups* Groups( )
Returns the Groups Collection object for a document.
- DimStyles [ReadOnly]
IAcadDimStyles* DimStyles( )
Returns the DimStyles Collection object for a document.
- Layers [ReadOnly]
IAcadLayers* Layers( )
Returns the Layers Collection object for a document.
- Linetypes [ReadOnly]
IAcadLineTypes* Linetypes( )
Returns the Linetypes Collection object for a document.
- Dictionaries [ReadOnly]
IAcadDictionaries* Dictionaries( )
Returns the Dictionaries Collection object for a document.
- RegisteredApplications [ReadOnly]
IAcadRegisteredApplications* RegisteredApplications( )
Returns the RegisteredApplications Collection object for a document.
- TextStyles [ReadOnly]
IAcadTextStyles* TextStyles( )
Returns the TextStyles Collection object of a document.
- UserCoordinateSystems [ReadOnly]
IAcadUCSs* UserCoordinateSystems( )
Returns the UCSs Collection object of a document.
- Views [ReadOnly]
IAcadViews* Views( )
Returns the Views Collection object of a document.
- Viewports [ReadOnly]
IAcadViewports* Viewports( )
Returns the Viewports Collection object of a document.
- ElevationModelSpace
Double ElevationModelSpace( )
Specifies or returns the elevation in modelspace.
- ElevationPaperSpace
Double ElevationPaperSpace( )
Specifies or returns the elevation in paperspace.
- Limits
VARIANT Limits( )
Specifies or returns the drawing limits of a document.
- Layouts [ReadOnly]
IAcadLayouts* Layouts( )
Returns the Layouts Collection object for a document.
- PlotConfigurations [ReadOnly]
IAcadPlotConfigurations* PlotConfigurations( )
Returns the PlotConfigurations Collection object for a document.
- Preferences [ReadOnly]
IAcadDatabasePreferences* Preferences( )
Returns the Preferences object for a document.
- FileDependencies [ReadOnly]
IAcadFileDependencies* FileDependencies( )
Returns the FileDependencies Collection object for a document.
- SummaryInfo [ReadOnly]
IAcadSummaryInfo* SummaryInfo( )
Returns the SummaryInfo object for a document.
- SectionManager [ReadOnly]
IAcadSectionManager* SectionManager( )
Returns the SectionManager Collection object for a document.
- Materials [ReadOnly]
IAcadMaterials* Materials( )
Returns the Materials Collection object for a document.
- Plot [ReadOnly]
IAcadPlot* Plot( )
Gets the Plot object for the document
- ActiveLayer
IAcadLayer* ActiveLayer( )
Specifies the active layer
- ActiveLinetype
IAcadLineType* ActiveLinetype( )
Specifies the active linetype for the drawing
- ActiveDimStyle
IAcadDimStyle* ActiveDimStyle( )
Specifies the active DimensionStyle
- ActiveTextStyle
IAcadTextStyle* ActiveTextStyle( )
Specifies the active TextStyle for the drawing
- ActiveUCS
IAcadUCS* ActiveUCS( )
Specifies the active CCS for the drawing
- ActiveViewport
IAcadViewport* ActiveViewport( )
Specifies the active viewport for the drawing
- ActivePViewport
IAcadPViewport* ActivePViewport( )
Specifies the active paper space viewport for the drawing
- ActiveSpace
AcActiveSpace ActiveSpace( )
Toggles the active space between paper space and model space
- SelectionSets [ReadOnly]
IAcadSelectionSets* SelectionSets( )
Gets the SelectionSets collection for the document
- ActiveSelectionSet [ReadOnly]
IAcadSelectionSet* ActiveSelectionSet( )
Gets the active selection set for the drawing
- FullName [ReadOnly]
BSTR FullName( )
Gets the name of the application or document, including the path
- Name [ReadOnly]
BSTR Name( )
Specifies the name of the object
- Path [ReadOnly]
BSTR Path( )
Gets the path of the document, application, or external reference
- ObjectSnapMode
Boolean ObjectSnapMode( )
Specifies the setting of the EntitySnap mode
- ReadOnly [ReadOnly]
Boolean ReadOnly( )
Specifies if the document is read-only or read-write
- Saved [ReadOnly]
Boolean Saved( )
Specifies if the document has any unsaved changes
- MSpace
Boolean MSpace( )
Allows editing of the model from floating paper space viewports
- Utility [ReadOnly]
IAcadUtility* Utility( )
Gets the Utility object for the document
- PickfirstSelectionSet [ReadOnly]
IDispatch* PickfirstSelectionSet( )
Gets the pickfirst selection set
- Active [ReadOnly]
Boolean Active( )
Determines if the document is the active document for the session
- WindowState
Void WindowState( )
Specifies the state of the application or document window
- WindowState [ReadOnly]
AcWindowState WindowState( )
Specifies the state of the application or document window
- Width
Void Width( )
Specifies the width of the text boundary, view, image, toolbar, or main application window
- Width [ReadOnly]
Int Width( )
Specifies the width of the text boundary, view, image, toolbar, or main application window
- Height
Void Height( )
Height of the attribute, shape, text, or view toolbar or the main application window
- Height [ReadOnly]
Int Height( )
Height of the attribute, shape, text, or view toolbar or the main application window
- ActiveLayout
Void ActiveLayout( )
Specifies the active sheet
- ActiveLayout [ReadOnly]
IAcadLayout* ActiveLayout( )
Specifies the active sheet
- HWND [ReadOnly]
Integer HWND( )
Gets the window handle of the document window frame
- WindowTitle [ReadOnly]
BSTR WindowTitle( )
Gets the title of the document window
- Application [ReadOnly]
IAcadApplication* Application( )
Gets the Application object
- Database [ReadOnly]
IAcadDatabase* Database( )
Gets the database in which the object belongs
- BeginSave()
Void BeginSave([in, optional] Int FileName)
Triggered immediately after Argon receives a request to save the drawing
- EndSave()
Void EndSave([in, out] Unknown FileName)
Triggered when Argon has finished saving the drawing
- BeginCommand()
Void BeginCommand([in, optional] Unknown CommandName)
Triggered immediately after a command is issued, but before it completes
- EndCommand()
Void EndCommand([in, optional] Unknown CommandName)
Triggered immediately after a command completes
- BeginLisp()
Void BeginLisp([in, optional] Unknown FirstLine)
Triggered immediately after Argon receives a request to evaluate a LISP expression
- EndLisp()
Void EndLisp( )
Triggered upon completion of evaluating a LISP expression
- LispCancelled()
Void LispCancelled( )
Triggered when the evaluation of a LISP expression is cancelled
- SelectionChanged()
Void SelectionChanged( )
Triggered when the current pickfirst selection set changes
- Activate()
Void Activate( )
Triggered when a document window is activated
- Deactivate()
Void Deactivate( )
Triggered when the drawing window is deactivated
- BeginRightClick()
Void BeginRightClick([in, out] Unknown PickPoint)
Triggered after the user right-clicks on the drawing window
Void BeginShortcutMenuDefault([in, optional] IDispatch* ShortcutMenu)
Triggered after the user right-clicks on the drawing window, and before the shortcut menu appears in default mode
Void BeginShortcutMenuEdit([out] IDispatch** ShortcutMenu, [in] IDispatch* SelectionSet)
Triggered after the user right-clicks on the drawing window, and before the shortcut menu appears in edit mode
- BeginShortcutMenuCommand()
Void BeginShortcutMenuCommand([in] BSTR ShortcutMenu, [in, optional] IDispatch* Command)
Triggered after the user right-clicks on the drawing window, and before the shortcut menu appears in command mode
Void BeginShortcutMenuGrip([in, optional] IDispatch* ShortcutMenu)
Triggered after the user right-clicks on the drawing window, and before the shortcut menu appears in SGrip mode
Void BeginShortcutMenuOsnap([in, optional] IDispatch* ShortcutMenu)
Triggered after the user right-clicks on the drawing window, and before the shortcut menu appears in ESnap mode
Void EndShortcutMenu([in, optional] IDispatch* ShortcutMenu)
Triggered after the shortcut menu appears
- BeginDoubleClick()
Void BeginDoubleClick([in, optional] Unknown PickPoint)
Triggered after the user double-clicks on an object in the drawing
- ObjectAdded()
Void ObjectAdded([in, out] Unknown Object)
Triggered when an object has been added to the drawing
- ObjectErased()
Void ObjectErased([in, out] ObjectId)
Triggered when an object has been erased from the drawing
- ObjectModified()
Void ObjectModified([in] Object)
Triggered when an object in the drawing has been modified
- BeginPlot()
Void BeginPlot([in] DrawingName)
Triggered immediately after Argon receives a request to print a drawing
- EndPlot()
Void EndPlot([in, optional] DrawingName)
Triggered after a document has been sent to the printer
- WindowMovedOrResized()
Void WindowMovedOrResized([in] Boolean HWNDFrame, [out] Unknown bMoved)
Happens when the drawing window is moved or resized.
- LayoutSwitched()
Void LayoutSwitched([in, out] LayoutName)
Triggered after the user switches to a different sheet
- WindowChanged()
Void WindowChanged([in, out] WindowState)
Triggered when there is a change to the application or document windows
- BeginClose()
Void BeginClose( )
Triggered immediately after Argon receives a request to close a drawing
- BeginDocClose()
Void BeginDocClose([in, optional] Boolean Cancel)
Triggered before the BeginClose event. This is an opportunity to cancel the closing process