1 Reply Latest reply on Jan 26, 2018 1:33 PM by Jacob Corder

    Hybrid add-in projects

    Ioan Bordei

      I have the following scenario:

      A SolidWorks third-party add-in (ADDIN1) offers an API for customizing diverse function/operations of it.

      I like to start SolidWorks from a console app (an .exe file) and access the API of the ADDIN1, but taking into consideration that the .exe  runs in a separate process than SolidWorks/ADDIN1. 

      My though was to access the ADDIN1 functions through another add-in (ADDIN2) which communicates with the exe in real time

      It is possible this scenario?

      How can this be accomplished?

      There are any examples/directions to look for?

      Any idea is welcome!

      Ioan

        • Re: Hybrid add-in projects
          Jacob Corder

          Just write the addin.

          Then anything else can communicate with that add-in using

          Isldworks.getaddinobject

           

          So dim myaddin as addintype = swappable.GetAddinObject(Guid of your addin)

           

          Now you have the live instance of your addin inside of solidworks.

           

          Anything made public is accessible. Basically you can do whatever you want it to do.

           

          No need to run solidworks in a separate .exe.

           

          Since the solidworks objects are thread safe as i understand (because they are com objects ), you shouldn't have any issues with that.