Solid Edge Framework Type Library
GetPSMGaugeInfoForDoc Method
Specify sheet metal document.
Returns current Gage.
Returns path of Gage file.
Returns number of Materials using excel.
Returns Material Gage Table name.
Returns number of documents using excel.
Returns document Gage table name.
Returns count of Bend Radius value.
Returns count of Bend Angle Value.
Returns count of Bend Natural factor Value.
Description
This API is used to get all the gage related information from a sheet metal document.
Syntax
Visual Basic
Public Sub GetPSMGaugeInfoForDoc( _
   ByVal pDocument As Object, _
   ByRef bstrGageName As String, _
   ByRef bstrGageFilePath As String, _
   ByRef iMTLUsingExcel As Integer, _
   ByRef bstrMTLGageTableName As String, _
   ByRef iDocUsingExcel As Integer, _
   ByRef bstrDocGageTableName As String, _
   ByRef iCountBendRadiusVals As Integer, _
   ByRef iCountBendAngleVals As Integer, _
   ByRef iCountNFVals As Integer _
) 
Parameters
pDocument
Specify sheet metal document.
bstrGageName
Returns current Gage.
bstrGageFilePath
Returns path of Gage file.
iMTLUsingExcel
Returns number of Materials using excel.
bstrMTLGageTableName
Returns Material Gage Table name.
iDocUsingExcel
Returns number of documents using excel.
bstrDocGageTableName
Returns document Gage table name.
iCountBendRadiusVals
Returns count of Bend Radius value.
iCountBendAngleVals
Returns count of Bend Angle Value.
iCountNFVals
Returns count of Bend Natural factor Value.
Example
Private Sub GetPSMGaugeInfoForDoc_Click(sender As Object, e As EventArgs) Handles GetPSMGaugeInfoForDoc.Click
    Dim objApplication As SolidEdgeFramework.Application = Nothing
    Dim objSMDoc As SolidEdgePart.SheetMetalDocument = Nothing
    Dim myMatTable As SolidEdgeFramework.MatTable = Nothing
    Dim strCurrGageName As String = ""
    Dim strGageFilePath As String = ""
    Dim nMTLUsingExcel As Integer
    Dim strMTLGageTableName As String = ""
    Dim nDocUsingExcel As Integer
    Dim strDocGageTableName As String = ""
    Dim nCountBendRadiusVals As Integer
    Dim nCountBendAngleVals As Integer
    Dim nCountNFVals As Integer

    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.GetPSMGaugeInfoForDoc(objSMDoc,
                                  strCurrGageName,
                                  strGageFilePath,
                                  nMTLUsingExcel,
                                  strMTLGageTableName,
                                  nDocUsingExcel,
                                  strDocGageTableName,
                                  nCountBendRadiusVals,
                                  nCountBendAngleVals,
                                  nCountNFVals)

        MsgBox("Current Gage:  " + strCurrGageName)
        MsgBox("Current Gage File:  " + strGageFilePath)
        MsgBox("Material Using Excel:  " + nMTLUsingExcel.ToString)
        MsgBox("Material Gage Table:  " + strMTLGageTableName)
        MsgBox("Document Using Excel:  " + nDocUsingExcel.ToString)
        MsgBox("Document Gage Table:  " + strDocGageTableName)
        MsgBox("Count Of Bend Radius Values:  " + nCountBendRadiusVals.ToString)
        MsgBox("Count Of Bend Angle Values:  " + nCountBendAngleVals.ToString)
        MsgBox("Count Of Bend Neutral Factor Values:  " + nCountNFVals.ToString)
    Catch ex As Exception
        MsgBox(ex.ToString)
    End Try
End Sub
See Also

MatTable Object  | MatTable Members  | Solid Edge ST5 - What's New