2 Replies Latest reply on Jun 7, 2017 1:49 AM by Prabaharan Pichaiyan

    Update custom property value using same macro

    Prabaharan Pichaiyan

      I created simple macro to input Custom property value, but once i triggered that macro i can't use that same filed to update the values.

      For Example If i give the Quantity value as 800 there after i can't update that value using the same macro with different value.

       

      Sub main()

      Dim swApp As SldWorks.SldWorks

      Dim swModel As SldWorks.ModelDoc2

      Dim swCustPropMgr As SldWorks.CustomPropertyManager

      Set swApp = Application.SldWorks

      Set swModel = swApp.ActiveDoc

      Set swCustPropMgr = swModel.Extension.CustomPropertyManager(Empty)

       

      swCustPropMgr.Add2 "Quantity", swCustomInfoNumber, "800"

       

       

      End Sub

       

      Is there any option available to do that?

       

      Thanks