Application: CreateComplexAreaRein
Revit Platform: Structure
Revit Version: 2011.0
First Released For: 9.0
Programming Language: C#
Skill Level: Medium
Category: Structure
Type: ExternalCommand

Subject: Create AreaReinforcement.
Summary: 
This sample demonstrates how to create AreaReinforcement by Revit API and change its parameters.

Classes: 
Autodesk.Revit.DB.Structural.AnalyticalModel
Autodesk.Revit.DB.CurveArray
Autodesk.Revit.DB.Line
Autodesk.Revit.DB.Structural.AreaReinforcementType
Autodesk.Revit.DB.ElementIterator
Autodesk.Revit.DB.Solid

Project Files:
CreateComplexAreaRein.cs
Implement the IExternalCommand interface, and show user how to create AreaReinforcment and change its parameters.

AreaReinData.cs
Data and data manager of the AreaReinforcement. Store all kinds of AreaReinforcementType in current project and contain method use to change value of parameter.

GeomUtil.cs
This file defines a class GeomUtil provides some common geometry estimate and calculates methods.

ParameterUtil.cs
This file defines a class ParameterUtil contains methods use to manage parameter. Such as find parameter by name and change value of parameter.

Description: 
-	This sample shows how to create AreaReinforcement by Revit API and set the parameter.
-	Create slab reinforcement with all four layers, and with two rectangular curve loops, nested, so that we have a rectangular opening.
-	On the interior 4 curves, set the override flag and flip the hooks on the top 2 layers to “up”.
-	The type used for creating Area Reinforcement can be found in the project if user has loaded an AreaReinformentType in the project.
-	The slab/wall’s geometry information is available as Geometry property of the Floor/Wall object.
-	The property ‘layout rule’ can be found from the Area Reinforcement by using the following generic parameters: REBAR_SYSTEM_LAYOUT_RULE
-	The properties of the AreaReinforcement Curve can be obtained by following generic parameters:
Name	Build in Parameter	
Override Area Reinforcement Settings	REBAR_SYSTEM_OVERRIDE	
Top Major Hook Orientation	REBAR_SYSTEM_HOOK_ORIENT_TOP_DIR_1	
Top Minor Hook Orientation	REBAR_SYSTEM_HOOK_ORIENT_TOP_DIR_2	

Instructions: 
1.	Draw a rectangular Slab (or open CreateComplexAreaRein.rvt) and Select it. 
2.	Run this command.