0 Replies Latest reply on Jun 10, 2007 1:36 AM by m mhb

    Please give me some advice about cosmosmotion code

    m mhb
      I cannot get the root object of cosmosmotion, Please give me someadvice about cosmosmotion code


      Sub main()
      Dim swApp As SldWorks.SldWorks
      Dim addin As CMotionSWAddin
      Dim strDllFileName As String
      Dim return_value As Integer
      Set swApp = GetObject(, "SldWorks.Application")
      strDllFileName = "C:\Program Files\SolidWorks\COSMOSMotion ForSolidWorks\cmotionsw.dll"
      return_value = swApp.LoadAddIn(strDllFileName)
      Set addin = swApp.GetAddInObject("COSMOSMotion")
      End Sub