In this part we’re going on a first exploration of Visual Studio 2008. Mind you: this is not a VS course. I will only highlight the parts I have used so far, probably disregarding a lot of extremely valuable functionality. And perhaps in a complete non-logical way. But hey, this is about Revit. Not VS. Go buy a book…
Visual Studio 2008
So, halfway through the day, I get to actually start up VS and go to work. Since Microsoft started deploying VS 2010, the 2008 version can no longer be downloaded from their site (or at least, I couldn’t find it). Luckily for me, and anyone else reading this and wanting to start: I posted the installer on www.revitforum.org and will also be posting it on my own blog at www.mdr-advies.nl.
After installing it, you get the screen as shown in the picture below.
Visual basic startup screen
You can start by opening a new project through the Recent Projects subscreen, in which case the following screen will open.
Start a new project
There are some different templates, which I haven’t all figured out quite yet. If memory serves me well, these are the different types:
- Windows Form Application: This is a standalone windows application with no interaction to other running programs.
- Class Library: This is the one you will mostly need, a plugin inside a host software.
- WPF Application: I have no clue as to what this does… Any comments from the API gurus out there?
- WPF Browser Application: Same here…
- Console Application: these are pieces of software that run automated without any user input. These are those MS-DOS-boxes that float around from time to time when installing software. Usually they perform tasks like extracting files to a certain folder, or cleanup installation files after Setup.
After starting a Class Library Template you will see this screen:
Class Library Template startup screen
First off: what in the world does this all mean?
The big screen is the coding screen, here you create the actual program code that makes your Addin do stuff. On the right side there is a palette which contains all sorts of project data. In Revit terms, this would be the project browser. Let’s focus on that one in the next post...