IDMDocument interface implemented only for
backward compatibility with DM2000. Use IDMDocument2 interface instead.
| Kind | Name | ID | Description |
| WindowCaption | 1 | Change DataForm.Caption | |
| WindowState | 2 | Change DataForm.ViewState | |
| Container | 3 | Return IDMContainer | |
| Worksheet | 4 | Return IDMWorksheet | |
| Plot | 5 | Return IDMPlot | |
| IsRecording | 6 | Change DataForm.Recording | |
| Activate | 7 | Activate window and restore if minimized | |
| Close | 8 | Close window | |
| SaveUndoInfo | 9 | Save Undo Information |
| property WindowCaption: BSTR |
Changes window title (or caption). Don't mix window caption and the file name, associated with data container object!
| property WindowState: User_Defined |
This property controls window view. It can have one of the values listed in the WindowStates enumeration. Do not mix this property with WindowSize that reflects "size" state!
| r/o property Container: IDispatch |
For DMDocument and DMSerie objects, Container property returns reference to the associated DMContainer object. Notice that for DMSerie object, this property is read/write, that is, you can assign to it container of any document.
For DMDigitizer, this property returns reference to the DMDigitizerContainer object, which is used only to store points coordinates.
| r/o property Worksheet: IDispatch |
Returns reference to the DMWorksheet object.
| property IsRecording: Boolean |
For DMDocument, this property indicates whether appropriate data window is in the "recording" state, that is, used for recording data from the measurement system (or for another real-time data streaming). Such window has a thick colored frame. Besides, "recording" data window is not only a visual feedback - it doesn't refresh plot when you set Container.Modified=true, and doesn't refresh Series Manager when you set Container.Modified=false (although worksheet updates its size). This feature should be used to eliminate flickers and significantly increase data streaming rates (and reduce CPU load). In addition, value of this property analyzed in the IDMApplication.RecordPoint() method.
For DMSerie, this property reflects the fact that this series is used to display accumulated data. When it is set to True, a little cross is displayed at the last point. Set IsRecording property to indicate that you are adding points into this series.
| function Activate: VOID |
Only one of MDI child windows may be active, that is, has input focus. For DMDocument, this procedure
makes document window active. Note that activation can change index of document in the Documents property.
For DMSerie object, Activate just makes this series active, or current, by changing IDMPlot.SerieIndex property. Of course, its position in the Series
array does not change.
' DMDocument: dim Doc set Doc=Server.Documents(1) Doc.Activate ' DMSerie: Server.ActiveDocument.Plot.Series(2).Activate
| function Close: VOID |
For DMDocument, this procedure closes document window. It is similar to Window|Close menu command.
For DMIEEE488Port, DMClientSocket, DMComPort and DMComTerminal, Close method closes the appropriate communication port.
DMDLLHelper.Close unloads DLL so that all subsequent API calls become impossible. DMAppHelper.Close also clears internal reference to DM2003 DOM. It is recommended to close these objects after use.
DMApplication.Close should be invoked to terminate DM2003. Unlike executing ExitAction, it does not display COM server warning for external (out of process) servers. For example, you may place following code in the HTML page loaded into the separate instance of MSIE browser:
sub Btn_onclick
dim app
set app=CreateObject("DM.DMApplication")
' do something useful...
. . . . .
' wrong - does not avoid COM warning message:
'app.ExecuteCommand "ExitAction"
' right - nothing displayed if no unsaved data:
app.Close
set app=Nothing
end sub
| function SaveUndoInfo: VOID |
This method implemented only for backward compatibility with DM2000. Use SaveUndo() method instead, since it allows you to indicate which operation have modified data.