How to delete Image2d object in Solid Edge using API?
SolutionCustomer can use ActiveSelectSet.Delete() method to delete Image2d object.
Sample code looks like,
Dim objApplication As SolidEdge.Framework.Interop.Application = Nothing
Dim objDraftDoc As SolidEdge.Draft.Interop.DraftDocument = Nothing
Dim objSheet As SolidEdge.Draft.Interop.Sheet = Nothing
Dim Image2d As SolidEdge.FrameworkSupport.Interop.Image2d = Nothing
Try
objApplication = Marshal.GetActiveObject("SolidEdge.Application")
objDraftDoc = objApplication.ActiveDocument
objSheet = objDraftDoc.ActiveSheet
For Each objimage As SolidEdge.FrameworkSupport.Interop.Image2d In objSheet.Images2d
objApplication.ActiveSelectSet.Add(objimage)
Next
objApplication.ActiveSelectSet.Delete()
Catch ex As Exception
MsgBox(ex.ToString)
End Try