Developer forum
cancel
Showing results for 
Search instead for 
Did you mean: 

New Developer - Can't Build Examples

Matt Balaam
Booster
Hi,

I am new to developing add-ons and also new to C++ (I have done programming in other languages before). I have installed the Dev Kit 14.2550 and Visual C++ 2005 Express and read everything I can find on building the example projects but cannot get any examples to build (I'm not even sure if I'm doing it right). Once I can get something running I can learn from there.

The documentation says that all the examples should build in Visual Studio 2005 Express, but I can't find anywhere exactly how to build them (coming from a beginners point of view)

If I try to build the whole solution, it comes up with an error like this...
1>BSCMAKE: error BK1506 : cannot open file '.\debug\Attribute_Test.sbr': No such file or directory
If I compile just the grc files separately, they succeed but don't seem to be of any use.

If I compile the rc2 file separately I get a "cannot find windows.h" error.

It would be greatly appreciated if someone could please get me started with an example of how to correctly open and build one of the example projects (as in which buttons to click to make it work), and any settings that I need to get up and running?

Thanks in advance,

Matt
AC21 (8002 AUS FULL) | AC24 (4018 AUS FULL)| Windows 10 Pro | Intel Core i7-6700 @ 3.40GHz | 16GB RAM | NVidia Quadro K620
7 REPLIES 7

Ralph Wessel
Mentor
mcjh_matt wrote:
The documentation says that all the examples should build in Visual Studio 2005 Express, but I can't find anywhere exactly how to build them (coming from a beginners point of view)
The documentation calls for Microsoft Visual C++ .NET 2005. I don't know if Express will do the same job, but I haven't tried to make it work either.
Ralph Wessel BArch

Matt Balaam
Booster
True, the documentation does say Microsoft Visual C++ .NET 2005, although I have read in other posts that Express is capable of building the addons with a few tweaks, I'm just not sure how to go about it.
AC21 (8002 AUS FULL) | AC24 (4018 AUS FULL)| Windows 10 Pro | Intel Core i7-6700 @ 3.40GHz | 16GB RAM | NVidia Quadro K620

Anonymous
Not applicable
Likewise, I would have similar questions and similar needs. Earlier this week I asked GS TS if there were API intro classes which would cover just the sorts of things that arise at the beginning, and are stumbling blocks that are real enthusiasm killers. Such courses are offered "on demand," so to speak. Should we "demand?"

Ralph Wessel
Mentor
didrik wrote:
I asked GS TS if there were API intro classes which would cover just the sorts of things that arise at the beginning, and are stumbling blocks that are real enthusiasm killers"
The best approach is to follow the API requirements as closely as possible, e.g. use Microsoft Visual C++ .NET 2005 rather than Express. You should then find that you can open, build, and run the examples without any problems.
Ralph Wessel BArch

Matt Balaam
Booster
Hi Ralph, yes I agree it is always best to follow the requirements as closely as possible, but when the requirements call for a software package that is no longer available that gets a bit difficult. If GS want to encourage developers to create add-ons for their software, they need to at least update the developer environment to support software that is actually available.

Since starting this thread, and after many hours of tinkering, I have infact managed to build and load the examples using Visual C++ Express 2008. This was a very convoluted process though with no real explanations anywhere. I am using Windows 7 64-bit which made the process even more difficult as express versions don't support 64-bit out of the box.

I'll post the steps I took to get it to work for future reference. One thing to note, the process for using 64-bit in Express involves editing the registry so if you aren't confident with this I wouldn't suggest trying it.

1. Download and install the correct API DevKit for your ArichCAD version

2. Download and install Visual C++ Express 2008 and any available service packs

3. Download and install Windows 7 SDK (I had to download the ISO file (~450MB) as the web installer would not install)

4. Follow the instructions on the following site to add 64-bit compatibility to Visual C++ Express 2008
http://jenshuebel.wordpress.com/2009/02/12/visual-c-2008-express-edition-and-64-bit-targets/

5. Open an example project in C++. It will open the conversion wizard to convert the project to the newer version, just follow the prompts

6. Open the project properties, then under Configuration Properties -> C/C++ -> General -> Additional Include Directories add the "Src" folder for the project you are trying to build.

7. Select the desired build configuration (I have had success with Debug | x64) and build the project.

8. Copy the generated apx file (in Debug or Release folder depending on your build configuration) into the ArchiCAD addons folder and launch ArchiCAD in demo mode. The addon should now be available in the addon manager. Alternatively you can manually load the addon from any folder you wish.

I can't guarantee there won't be other little things you have to adjust but this has allowed me to build working examples and at least get started with the development process. I hope this can help some fellow beginners.
AC21 (8002 AUS FULL) | AC24 (4018 AUS FULL)| Windows 10 Pro | Intel Core i7-6700 @ 3.40GHz | 16GB RAM | NVidia Quadro K620

Ralph Wessel
Mentor
mcjh_matt wrote:
when the requirements call for a software package that is no longer available that gets a bit difficult. If GS want to encourage developers to create add-ons for their software, they need to at least update the developer environment to support software that is actually available.
Bear in mind that using a 2008 version rather than 2005 may lead to other problems during runtime, which can be very difficult to solve. Getting it to build is only the first hurdle.
Ralph Wessel BArch

Anonymous
Not applicable
I have the same problem when i am trying to comple the exemples.
I have Visual Studio 2005 .net installed but i am thinking is a problem from de O.S. I am using W7 64 bits.

Please help.

Still looking?

Browse more topics

Back to forum

See latest solutions

Accepted solutions

Start a new discussion!