Solid Edge Framework Type Library
GetCurrentGageName Method
Specify Sheet metal document.
Returns name of currently applied Gage as string.
Description
This method is used to fetch the name of currently applied gage of a sheet metal document.
Syntax
Visual Basic
Public Sub GetCurrentGageName( _
   ByVal pDocument As Object, _
   ByRef bstrGageName As String _
) 
Parameters
pDocument
Specify Sheet metal document.
bstrGageName
Returns name of currently applied Gage as string.
Example
Private Sub GetCurrentGageName_Click(sender As Object, e As EventArgs) Handles GetCurrentGageName.Click
    Dim objApplication As SolidEdgeFramework.Application = Nothing
    Dim objSMDoc As SolidEdgePart.SheetMetalDocument = Nothing
    Dim myMatTable As SolidEdgeFramework.MatTable = Nothing
    Dim strGageName As String = ""

    Try
        objApplication = Marshal.GetActiveObject("SolidEdge.Application")
        ' Get the material table object from the application
        myMatTable = objApplication.GetMaterialTable()

        objSMDoc = objApplication.ActiveDocument
        If (objSMDoc Is Nothing) Then
            MsgBox("Failed to get Sheet Metal Document object.")
        End If

        Call myMatTable.GetCurrentGageName(objSMDoc, strGageName)
        MsgBox("Current Gage Name:   " + strGageName)

    Catch ex As Exception
        MsgBox(ex.ToString)
    End Try
End Sub
See Also

MatTable Object  | MatTable Members