Private Sub Command1_Click()
On Error Resume Next
Dim objApplication As SolidEdgeFramework.Application
Dim objSolidEdgeInsightXT As SolidEdgeFramework.SolidEdgeInsightXT
Set objApplication = GetObject(, "SolidEdge.Application")
Set objSolidEdgeInsightXT = objApplication.SolidEdgeInsightXT
Dim ItemRevIds As Variant
Dim nCount As Long
Dim iIndex As Integer
Dim seTypes As TCESETypes
Dim strUserName As String
seTypes = TCE_SEAssembly
strUserName = "User"
nCount = 0
'Provide empty user name if you want to search in whole database
Call objSolidEdgeInsightXT.GetItemRevBasedOnSEType(seTypes, strUserName, ItemRevIds)
If Not IsEmpty(ItemRevIds) Then
nCount = UBound(ItemRevIds)
For iIndex = 0 To nCount
'ItemRevIds(iIndex, 0) = Item ID whose dataset type equal to the input type (TCE_SEAssembly)
'ItemRevIds(iIndex, 1) = Revision ID whose dataset type equal to the input type (TCE_SEAssembly)
Next
End If
Set objSolidEdgeInsightXT = Nothing
Set objApplication = Nothing
End Sub