Archicad C++ API
About Archicad add-on development using the C++ API.

Add-On undefined

Anonymous
Not applicable
Not sure if this is really two separate issues or one question with supporting clues. If I need to bust it up into two questions, let me know.

I can successfully build my menu add-on. I have redirected my pointer for 'Use designated Add-Ons folder:' to a network location. The .apx file is in the correct network location to automatically load when I start Archicad. All menu functionality works as expected. When I set a coworkers 'Use designated Add-Ons folder:' pointer to the same network location, he is not able to load the menu. Selecting the Add-On from the 'AVAILABLE ADD-ONS' list in the Add-On Manager shows the correct file from the right location but displays a message of 'The file is an outdated Add-On that cannot be used with this Archicad version.' [see attached] We are running the same build of Archicad and loading the same .apx Add-On file, only I can do this successfully and he cannot.

When I look at the database in the Archicad AddOnAdmin tool, my .xml file is displayed in red text. [see attached] The official documentation on this tool shows the .xml file in green. When I switch to the 'Check' tab and 'Load' the .apx file from the network location, the analysis shows 'DevKit Version: Undefined (Undefined release)'. [see attached] In VS, my 'Solution Configurations' is set to 'Debug' and my 'Solution Platforms' is set to 'x64'. [see attached]

Am I missing a step somewhere to be able to register this first add-on for network use? Am I missing a step somewhere on how I build the .apx file? Would taking my developer / add-on credentials out of the Fix.grc file and putting them in a header file make this more portable? It appears that the .grc file is included with the build.

Thanks for the insight.
4 REPLIES 4
Tibor Lorantfy
Graphisoft Alumni
Graphisoft Alumni
Hi Chris,

Does your Add-On have any external DLL dependency?
In Windows platform ARCHICAD tries to load the DLL dependencies of the Add-Ons from the folder where ARCHICAD.exe can be found.
So if your Add-On requires a DLL and you copied that DLL next to your ARCHICAD but your coworker didn't, then it could be the reason.

I suggest you to build your Add-On using Release configuration if you publish your Add-On. So please switch Debug to Release and try it again.

Regards,
Tibor
Anonymous
Not applicable
Hey Tibor,

There is no external DLL dependency. All add-on dependency is contained within the build of the .cpp and the associated header and .grc files.

Good call on emphasizing to build using the Release configuration. We did try that yesterday and it did not make a difference.

I should also add that I have successfully made edits to a couple of other coworkers 'Use designated Add-Ons folder:' pointer and they were able to find my add-on at the preferred network location. I intentionally have everyone in the studio looking at a single network copy of my tools and it either works for all or for none. This helps direct attention to problems either with my code or individual problems that usually tend to be more machine config related. More often than not, a user will approach with "Hey, your stuff is not working" when in reality it is "Well, it works for me. Your [machine/configuration] is the problem."
Anonymous
Not applicable
It seems I have a similar problem.
On the computer with SDK, everything seems to work ok.
But when I move apx file to another computer it doesn't recognize it as AddOn. Both computers have the same version of AC.

With both compiler setup - Release and Debug - I got a message in Addon manager of AC that this is an old version of the plugin not compatible with this version of AC.

have tried debugging in two directions:

1. Missing library
I checked all warnings in Debug mode and found out that ACAP_STATD.lib is has been not linked to the current build. It seems to work now after changing compiler settings and library version (ACAP_STAT.lib for Release).

2. Missing Resources
When I tested with Check tool in AddOn Management I got the same result as Chris. -> "Undefined Release"

I thought that it might be because I don't have any info about AddOn version. So I tried Karl's solution:
https://archicad-talk.graphisoft.com/viewtopic.php?f=23&t=28755&p=148654&hilit=missing+resources#p14...

I stuck here because the compiler can't access modified grc file. So compilation stops.
Anonymous
Not applicable
Update:
Done. The plugin is working on different stations and in AddOn Management Check.

In my case, it was a mess in Compiler Setup after a bunch of tests.
What worked was setting up from scratch. It's much easier to do it by editing .vproj. I started form coping fresh configuration form one of the example files and change my dependencies.

I think the reason was the setup of Resource manger it didn't do all its magic and therefore AddOn didn't pass the check. I hope it will help in your case Chris.

PS: Version in Resource file still doesn't work.