Friday, October 29, 2010

Visual C# 2010 Express

Hi all,


Normally I develop my code with Visual Basic 2010 Express. But today, I want to learn something about C#. So I downloaded Visual C# 2010 Express, installed it and open it.


I tried to do it the same as in VB however no luck. After some time I found out what I had to do. And here it is:


On page 21 of the "Revit 2011 API Developer Guide.pdf" you can find the first source code for HelloWorld. I did the steps, copied the code, build the program, created the right .addin file and so on. But still it did not work. The button was there, but when I hit it nothing happens...



Just check the following:
When you open the Properties of your project, the Application tab shows what Target framework will be used. In my situtation .NET Framework 4.0 had been set.

I changed it to .NET Framework 3.5 and now this simple extension works. Finally

Wednesday, October 13, 2010

Property palette disappears and Project browser part far too large

Hi,

I am working on a laptop and in the office I have two monitors attached to it. This all works fine, but for some reason the Property palette totally disappears and the Project browser palette is so big that I can not see the edge of it....???

So, I tried to use the Repair Software and Reinstall Software functionality, but they did not help.

Therefore, I looked into the Registry (regedit) and here is what I did:
1. Exit Revit 2011
2. Go to

HKEY_CURRENT_USER\Software\Autodesk\Revit\Autodesk Revit Structure 2011\Components\Panels

2. Select PropertiesPalette, press Change and Paste this into it:

L,0,0,0,1.000000,220,1721,470,300,300,N

3. Select ProjectBrowser, press Change and Paste this into it:

L,0,0,0,1.000000,220,1721,470,300,300,N

4. Close the Registry
5. Start Revit 2011

Now, both palettes will appear on the left side of your Revit screen. Success!!!

Friday, October 1, 2010

Import coordinates into Revit 2011

I updated the Revit 2010 extension for importing coordinates from a TXT file. You are free to select a family of your own. It should be a Point Based family of course.

You can download the extension here.

(It has been compiled for Windows XP 32 bits)

Wednesday, September 15, 2010

Export XYZ from Revit 2011

This extension for Revit 2011 exports all coordinates of Point Based Generic Models to an Excel file.

You can locate Point Based Generic Models in your whole model. You are able to nest such a Family within another. These points are exported as well when you make this family Shared.

Be patient, do not click anywhere in the Excel file untill you will receive a message that the export is ready!



This is the result:

You can download it here. (It has been compiled for Windows XP 32 bits)

Tuesday, July 20, 2010

Can not delete Subcategories in Imported Categories

Sometimes it happens that Subcategories are not deleted when you remove the DWG from your project or family. In the Visibility Graphics these Subcategories are stored and there is no way to purge this (even through Object Styles and remove it does not work). How to erase these items...

  1. Start AutoCAD

  2. Create a drawing with the exact same Layer names as you can find in the Subcategories

  3. Draw on each Layer a Line

  4. Go to Revit

  5. Import this AutoCAD drawing in your Revit project or family

  6. Select the Imported drawing

  7. Use Query and select one of the lines

  8. Press the button Delete

  9. Repeat step 7 and 8 for each layer

Now, your Revit project or family is completely purged from these Subcategories!