Solid Edge Framework Type Library
Application Property
Description
Returns the active application object.
Property type
Read-only property
Syntax
Visual Basic
Public Property Application As Object
Example
Private Sub Form_Load()
    Dim objApp As SolidEdgeframework.Application
    Dim objDoc As SolidEdgepart.PartDocument
    Dim objVariables As SolidEdgeframework.Variables
    Dim ObjVarsApp As SolidEdgeframework.Application
    ' Report errors
    Const PI = 3.14159265358979
    ' Create/get the application with specific settings
    On Error Resume Next
    Set objApp = GetObject(, "SolidEdge.Application")
    If Err Then
        Err.Clear
        Set objApp = CreateObject("SolidEdge.Application")
        Set objDoc = objApp.Documents.Add("SolidEdge.PartDocument")
        objApp.Visible = True
    Else
        Set objDoc = objApp.ActiveDocument
    End If
    'Get Variables Collection
    Set objVariables = objDoc.Variables
    'Get the Application object from Variables collection
    Set ObjVarsApp = objVariables.Application
    ' USER DISPLAY
    ' Release objects
    Set objApp = Nothing
    Set objDoc = Nothing
    Set objVariables = Nothing
    Set ObjVarsApp = Nothing
End Sub
See Also

Variables Collection  | Variables Members