Hello
swapp is declared as Sldworks.Sldworks
All related references are included.
I'm using Solidworks 2009 and writing this code in VB.net.
The assembly file "\\10.0.0.1\genel\Montaj.sldasm", which is an empty assembly file, does get opened but unfortunately It simply does not insert component "Kiris.Sldprt".
Appreaciate any help. Thanks in advance.
VB.NET:
Dim Part As SldWorks.AssemblyDoc
Dim yera As String
swapp = CreateObject("SldWorks.Application")
Part = swapp.OpenDoc2("\\10.0.0.1\genel\Montaj.sldasm", 2, False, False, True, 1)
swapp.Visible = True
yera = "\\10.0.0.1\genel\Kiris.SLDPRT"
Part.AddComponent4(yera, "", 0, 0, 0)
Part.EditRebuild()
All related references are included.
I'm using Solidworks 2009 and writing this code in VB.net.
The assembly file "\\10.0.0.1\genel\Montaj.sldasm", which is an empty assembly file, does get opened but unfortunately It simply does not insert component "Kiris.Sldprt".
Appreaciate any help. Thanks in advance.