The main oddities about using Inventor's iLogic, when you are used to coding in VBA or strict vb.net, is that they created iLogic to make automating Inventor much simpler for folks that do not already know much (if anything) about coding. When you create a new, empty iLogic rule, there are already several things taken care of for you in the background. It will automatically create a Class block of code for you (Class name is "ThisRule") invisibly, in the background, if you to not start your code with a Class statement. It will automatically create a 'Sub Main' block of code for you, invisibly, in the background, if you do not start your code with that key phrase. That way you can just start typing in useful code that will work on its own, without needing to know anything about that stuff. You only need to include those types of specifications when your rules need to call other, separate routines to run. There are also lots of variables already defined and created for us invisibly, in the background, that we can simply start using in our simple rules. Some of them represent Interface type objects, and have a lot of behind the scenes functionality to help reduce the amount of code needed. But our iLogic rules can also be very strict, and professional, like if they were copied straight over from something like Visual Studio, to a certain degree, when certain settings are set-up correctly. Even though iLogic is just an ApplicationAddIn within the Inventor application, it is actually capable of a lot more than most folks suspect, due to its coding language being based on vb.net.
https://help.autodesk.com/view/INVNTOR/2024/ENU/?guid=GUID-AB9EE660-299E-408F-BBE1-AFE44C723F59
https://help.autodesk.com/view/INVNTOR/2024/ENU/?guid=110f3019-404c-4fc4-8b5d-7a3143f129da
https://help.autodesk.com/view/INVNTOR/2024/ENU/?guid=UserManualIndex
Wesley Crihfield

(Not an Autodesk Employee)