Creates a non rectangular profile wall within the project using the specified wall type. 
   Namespace:   Autodesk.Revit.DB  
  Assembly:   RevitAPI  (in RevitAPI.dll) Version: 21.0.0.0 (21.1.1.109) 
Syntax
| C# | 
|---|
|  | 
| Visual Basic | 
|---|
|  | 
| Visual C++ | 
|---|
|  | 
Parameters
- document
-  Type:  Autodesk.Revit.DB Document  
 The document in which the new wall is created.
- profile
-  Type:  System.Collections.Generic IList   Curve  
 An array of planar curves that represent the vertical profile of the wall.
- wallTypeId
-  Type:  Autodesk.Revit.DB ElementId  
 Id of the wall type to be used by the new wall instead of the default type.
- levelId
-  Type:  Autodesk.Revit.DB ElementId  
 Id of the level on which the wall is to be placed.
- structural
-  Type:  System Boolean  
 If set, specifies that the wall is structural in nature.
Return Value
If successful a new wall object within the project.Exceptions
| Exception | Condition | 
|---|---|
| Autodesk.Revit.Exceptions ArgumentException | The input profile contains at least one helical curve and is not supported for this operation. | 
| Autodesk.Revit.Exceptions ArgumentNullException | A non-optional argument was NULL | 
| Autodesk.Revit.Exceptions InvalidOperationException | Failed to create the wall. | 
| Autodesk.Revit.Exceptions ModificationForbiddenException | The document is in failure mode: an operation has failed, and Revit requires the user to either cancel the operation or fix the problem (usually by deleting certain elements). -or- The document is being loaded, or is in the midst of another sensitive process. | 
| Autodesk.Revit.Exceptions ModificationOutsideTransactionException | The document has no open transaction. |