CAD Forum - tips, tricks, discussion and utilities for AutoCAD, Inventor, Revit and other Autodesk products [www.cadforum.cz] ARKANCE | CONTACT - CZ | SK | EN | DE

CAD tip CAD tip # 7714:

Question

CAD 
 %  platform  category 
A
If you program a macro or an add-on module for Revit, using either the integrated VSTA environment, or on of the Visual Studio .Net programming languages, sooner or later you will need a "magic" constant to multiply the size units.

Revit uses feet as internal units in its BIM database. You don't neccessarily see these units in the Revit UI as a user (if you use the metric settings) but you definitely need them as a programmer - and convert the internal values in some API functions. For these conversions you may need two constants:

Const MeterToFeet As Double = 3.2808399
Const FeetToMeter As Double = 0.3048
or - in millimeters:
Const MmToFeet As Double = 0.0032808399
Const FeetToMm As Double = 304.8
Revit
100% *CAD
7.1.2011   11354×  
   
this tip shared by ARKANCE experts applies to: Revit ·

See also:
Tip 13692:What is the precision in Revit?
Tip 12777:Arithmetic and trigonometric functions available in Revit expressions.
Tip 12624:How to enter dimensions in Revit using other units?
Tip 12609:Dynamo - how to convert a raster photo to 3D model in Revit?
Tip 11494:Entering decimal values using fractions in CAD applications.


Back    All CAD Tips



Have we helped you? If you want to support the CAD Forum web service, consider buying one of our CAD applications, or our custom software development offerings, or donating via PayPal (see above). You may also add a link to your web - like this "fan" link: CAD Forum - tips, utilities, blocks for Autodesk products
CAD: 
OS: 
Categ: 
Text:
 FAQ
  





Please use these tips at your own risk.
ARKANCE is not responsible for possible problems that may occur as a result of using any of these tips.
TOPlist