We recommend using VB.NET or other programming environment for production applications. (VBA could be removed in future versions of Inventor). However VBA can be useful for quick prototyping and debugging. In this screenshot you see the Watches window that shows the current values of a parameter at runtime. (When the break point was hit). You can use Debug.Print to print values in the immediate window. In this example the name property of the param is “holes”. Also the Object Browser provides a way to explore the objects in the Inventor API. You can display the Object Browser from the VBA View Menu (View>Object Browser or F2). You can select a library to search and a string to search on. In the screen shot below shows the Inventor Library is selected and the search is for Application. The selected class is Application. The selected member is the ActiveDocument property. (The Object Browser is also available in VB.NET) Set needed for Inventor API Be able to access an API based on COM (component Object Model) using a programming language such as VB.NET or C#. Know how to work with the Inventor API Objects (there are a lot of them) Advantages of using the Inventor API compared to iLogic rules Ability to create AddIns that have a User Interface (Ribbon elements, Toolbars, menus) Using iLogic rules to implement a user interface for a large application could be user unfriendly. Intellisense and debugging are available in tools such as VB.NET. (When you close the iLogic Edit Rule dialog, if there is a problem it will only tell you which line is causing the error) iLogic Introduction The main purpose of iLogic is to enable a way for companies to create different configurations of assemblies easily (by just changing a parameter). With iLogic the parameter is more than just a formula, but actually drives a program (rules) to create different configurations of an assembly,
We recommend using VB.NET or other programming environment for production applications. (VBA could be removed in future versions of Inventor). However VBA can be useful for quick prototyping and debugging. In this screenshot you see the Watches window that shows the current values of a parameter at runtime. (When the break point was hit). You can use Debug.Print to print values in the immediate window. In this example the name property of the param is “holes”. Also the Object Browser provides a way to explore the objects in the Inventor API. You can display the Object Browser from the VBA View Menu (View>Object Browser or F2). You can select a library to search and a string to search on. In the screen shot below shows the Inventor Library is selected and the search is for Application. The selected class is Application. The selected member is the ActiveDocument property. (The Object Browser is also available in VB.NET) Set needed for Inventor API Be able to access an API based on COM (component Object Model) using a programming language such as VB.NET or C#. Know how to work with the Inventor API Objects (there are a lot of them) Advantages of using the Inventor API compared to iLogic rules Ability to create AddIns that have a User Interface (Ribbon elements, Toolbars, menus) Using iLogic rules to implement a user interface for a large application could be user unfriendly. Intellisense and debugging are available in tools such as VB.NET. (When you close the iLogic Edit Rule dialog, if there is a problem it will only tell you which line is causing the error) iLogic Introduction The main purpose of iLogic is to enable a way for companies to create different configurations of assemblies easily (by just changing a parameter). With iLogic the parameter is more than just a formula, but actually drives a program (rules) to create different configurations of an assembly,
v1_CP2544_iLogic_Inventor_API.docx