Hi!
I am making a software in VB.NET that is changing components in an assembly (their configurations and dimensions). I recently discovered an issue with dimensions that are set with equation just stopped updating.
What I later found out is they only stop updating when SolidWorks is started by my software and not if it is already started! And I have tested this quite thoroughly.
When SolidWorks is already started I connect using:
swApp = GetObject(, "SldWorks.Application")
When SolidWorks is not started I connect using:
swApp = CreateObject("SldWorks.Application")
Furthermore, for both cases following code is executed afterwards:
swApp.Visible = True
swApp.DocumentVisible(True, swDocumentTypes_e.swDocPART)
swApp.DocumentVisible(True, swDocumentTypes_e.swDocASSEMBLY)
swApp.DocumentVisible(True, swDocumentTypes_e.swDocDRAWING)
swApp.DocumentVisible(True, swDocumentTypes_e.swDocSDM)
swApp.UserControl = True
Does anyone have an idea why equations would stop updating when SolidWorks is started by my software but not if it is already running?
Thank you in advance.
SolidworksApi macros