Run Add ins with ilogic

Run Add ins with ilogic

marko.jessenjuhler
Contributor Contributor
388 Views
2 Replies
Message 1 of 3

Run Add ins with ilogic

marko.jessenjuhler
Contributor
Contributor

Is there a way to call the Add-ins application with ilogic.

We have part/drawing export generated with add-in that export material to the PLM system.

 

Is there a way to run those functions that add in buttons does with logic? 

0 Likes
389 Views
2 Replies
Replies (2)
Message 2 of 3

Michael.Navara
Advisor
Advisor

For this purposes is in the Inventor.ApplicationAddInServer interface property Automation. You can provide your custom functionality thru this object.

 

For more information you can see this article

https://adndevblog.typepad.com/manufacturing/2012/07/connect-to-an-inventor-add-in-an-external-appli...

 

 

0 Likes
Message 3 of 3

JelteDeJong
Mentor
Mentor

There is a second option (that I personally prefer). This option has 2 advantages. In many cases, you don't have to change your adding. There is no need to create/use the Inventor.ApplicationAddInServer interface property Automation. The interface property Automation will always return a object of the type object. maybe not a big deal in iLogic/vb.net (but is very annoying in languages like c#) also you will lose the IntelliSense (code completion) in your code editor.

What you can do: In your rule, add a reference to the DLL of your adding and call its objects directly. For example, you have an adding with the following object:

JelteDeJong_0-1633719124407.png

then you can use them like this in your rule:

AddReference "c:\PATH\To\MyAddin.dll"
Imports MyAddon.NameSpace
' These 2 lines should be at the start of your rule!
Dim myObject As MyObject(ThisApplication)
myObject.showActiveDocumentName()

 

Jelte de Jong
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature


Blog: hjalte.nl - github.com

0 Likes