Community
Inventor Programming - iLogic, Macros, AddIns & Apprentice
Inventor iLogic, Macros, AddIns & Apprentice Forum. Share your knowledge, ask questions, and explore popular Inventor topics related to programming, creating add-ins, macros, working with the API or creating iLogic tools.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Registry Free

5 REPLIES 5
Reply
Message 1 of 6
KentKeller
554 Views, 5 Replies

Registry Free

I am finally starting to work in 2012.  While modifiying an Addin, I figured I would make it registry free, and started following the directions.  In the help, it says to uncheck, the "Register for COM interop" checkbox.  I am guessing it is a Express limitation, but there is no checkbox.   Is there somewhere else I can make this change in Express?

Kent Keller
KWiKMcad

5 REPLIES 5
Message 2 of 6
KentKeller
in reply to: KentKeller

I am pretty sure I found the right spaces to change this in the .vbproj file. 

Same thing with the post process. 

 

A couple of things I have found with the help file that appear to be wrong

 

mt.exe -manifest $(ProjectDir)\InvAddin.X.manifest -
outputresource:"$(TargetPath)";#2

First I found the \ after $(ProjectDir) was causing the call to end up with two \\.    By removing it I got the project to build once.

I also found that by adding quotes around "$(ProjectDir)InvAddin.X.manifest" it got rid of the error at least for one build attempt.

 

I am still getting a error 909 when trying to build.  I have noticed that when I run Set in a command window, there is no listing with VSxxxCOMNTOOLS.   I am suspecting this is what is currently keeping it from building.  I am starting to try to track that down, but if anyone knows what I need to do to make them availible I would appreciate the help.

 

Is anyone else converting existing addins to registry free and using express? 

Kent Keller
KWiKMcad

Message 3 of 6
KentKeller
in reply to: KentKeller

Still hoping for some help.

 

I ended up downloading the full trial version of Visual Studio, and that finally gave me VS100COMNTOOLS. 

 

I ask again, has anyone been able to create a registry free addin using VB.net Express?   It appears to me that the tools directory is not created in the Visual Studio xx\Common directory unless you install the non express version. 

 

Anyhow, I am now getting the following error when trying to build.  I can be blind, but I have checked the syntaxt a couple of times in both the post build event and the manifest file.     Anyone have any ideas?

 

The command "mt.exe -manifest C:\Users\KENT-Desktop\Documents\Visual Studio 2010\Projects\KWiKSert_64\KWiKSert_64.X.manifest -
outputresource:"C:\Users\KENT-Desktop\Documents\Visual Studio 2010\Projects\KWiKSert_64\bin\KWiKSert_64.dll";#2" exited with code 123.

Kent Keller
KWiKMcad

Message 4 of 6
Anonymous
in reply to: KentKeller

Hi Kent,

 

I started migrating an Addin to registry free but it is still not loading, nor registering in Inventor.

 

I can build everything, manifests embeded, .addin file set in the proper Inventor directory and part concerning COM registration removed from code.

 

As you mentionned, i had to remove the "\" from the command line and to set the quotes on the -manifest option and the outputresource. In fact, in the command line, you have to put quotes to pathes if they contain spaces ! But, to make it work, i had to call the mt.exe with the absolute path to the executable :

 

"C:\Program Files\Microsoft SDKs\Windows\v6.0A\Bin\mt.exe" -manifest "$(ProjectDir)Watch.X.manifest" -outputresource:"$(TargetPath)";#2

 

This command line is working in Visual Studio 2010, under Windows 7 64 bits. The "mt.exe" may be in other place on your PC.

 

But as i said, even if everything is compiling, manifest can be found in my dll, Inventor doesnt show my addin in the addin manager. Which means it is not even registered...

 

So again, as Kent Keller asked, if somebody has done this kind of migration with success, please share your experience.

 

Colin


Message 5 of 6
nmunro
in reply to: Anonymous

A couple of things:

 

For IV2012 it appears that the add-in must Targer .NET Framework 2.0. Targeting 4.0 results in an add-in that reports as "Unloaded".

 

The .addin files for all the Autodesk addins have the following xml declaration at the top of the file (don't think this makes a difference but it can't hurt)

 

<?xmlversion="1.0"encoding="utf-16"?>

        


https://c3mcad.com

Message 6 of 6
KentKeller
in reply to: KentKeller

I was lucky enough to get some help from someone in the Autodesk Developer Consultant team.  I have managed to now get two addins to work, but both times I am not sure what the final fix was.

 

One of the things is this is how my post build event looks

call "%VS100COMNTOOLS%vsvars32"
            mt.exe -manifest "$(ProjectDir)KWiKSert_64.X.manifest" -outputresource:"$(TargetPath)";#2

 

I am using Windows 7 and choosen Version Independent, so my .addin file goes here

%ALLUSERSPROFILE%\Autodesk\Inventor Addins\

with my dll in a subfolder with the <Assembly> in the .addin file pointing to it like this

KWiKSert_64\KWikSert_64.dll

 

I can't say for sure if it fixed the problem or not, but on both addins, I ran regedit and deleted pretty much anything that contained the name of the addin, other than MRU lists.  I am not sure if I have problems in my uninstall routines or ??  but there was a number of entries still in the registry after doing the uninstall.

 

I still haven't gotten debugging to work from Visual Studio, but I still have a couple things to look at later tonight.

Kent Keller
KWiKMcad

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report