Solid Edge Framework Type Library
GetPSMGaugeListFromExcel Method
Specify complete path of Gage table.
Returns Number of Gages in Gage Table.
Returns list of Gages in the form of an array.
Description
This method is used to obtain list of Gages from a Gage table.
Syntax
Visual Basic
Public Sub GetPSMGaugeListFromExcel( _
   ByVal bstrGageTableName As String, _
   ByRef plNumGages As Long, _
   ByRef listOfGages As Variant _
) 
Parameters
bstrGageTableName
Specify complete path of Gage table.
plNumGages
Returns Number of Gages in Gage Table.
listOfGages
Returns list of Gages in the form of an array.
Example
Private Sub GetPSMGaugeListFromExcel_Click(sender As Object, e As EventArgs) Handles GetPSMGaugeListFromExcel.Click
    Dim objApplication As SolidEdgeFramework.Application = Nothing
    Dim objSMDoc As SolidEdgePart.SheetMetalDocument = Nothing
    Dim myMatTable As SolidEdgeFramework.MatTable = Nothing
    Dim strGageList(0 To 100) As String
    Dim nNumofGages As Integer
    Dim strInputgageTable As String = "C:\Program Files\Solid Edge ST7\Preferences\Gagetable.xls"

    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.GetPSMGaugeListFromExcel(strInputgageTable, nNumofGages, strGageList)
    Catch ex As Exception
        MsgBox(ex.ToString)
    End Try
End Sub
See Also

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