cAreaObjAddByPoint Method |
Adds a new area object whose defining points are specified by name.
Namespace:
ETABS2016
Assembly:
ETABS2016 (in ETABS2016.dll) Version: 16.0.0.0 (16.0.0.0)
Syntaxint AddByPoint(
int NumberPoints,
ref string[] Point,
ref string Name,
string PropName = "Default",
string UserName = ""
)
Function AddByPoint (
NumberPoints As Integer,
ByRef Point As String(),
ByRef Name As String,
Optional PropName As String = "Default",
Optional UserName As String = ""
) As Integer
int AddByPoint(
int NumberPoints,
array<String^>^% Point,
String^% Name,
String^ PropName = L"Default",
String^ UserName = L""
)
abstract AddByPoint :
NumberPoints : int *
Point : string[] byref *
Name : string byref *
?PropName : string *
?UserName : string
(* Defaults:
let _PropName = defaultArg PropName "Default"
let _UserName = defaultArg UserName ""
*)
-> int
Parameters
- NumberPoints
- Type: SystemInt32
The number of points in the area object.
- Point
- Type: SystemString
- Name
- Type: SystemString
This is the name that the program ultimately assigns to the area object.
If no userName is specified, the program assigns
a default name to the area object. If a userName is specified
and that name is not used for another area object, the userName
is assigned to the area object; otherwise a default name is assigned to the area object.
- PropName (Optional)
- Type: SystemString
This is Default, None or the name of a defined area property.
If it is Default, the program assigns a default area property to the area object.
If it is None, no area property is assigned to the area object.
If it is the name of a defined area property, that property is assigned to the area object.
- UserName (Optional)
- Type: SystemString
Return Value
Type:
Int32
Returns zero if the area object is successfully added;
otherwise it returns a nonzero value.
Remarks
ExamplesPublic Sub Example()
Dim SapModel As cSapModel
Dim EtabsObject As cOAPI
Dim ret As Integer = -1
Dim Point() As String
Dim Name As String
EtabsObject = CreateObject("CSI.ETABS.API.ETABSObject")
ret = EtabsObject.ApplicationStart()
SapModel = EtabsObject.SapModel
ret = SapModel.InitializeNewModel()
ret = SapModel.File.NewSteelDeck(4, 12, 12, 4, 4, 24, 24)
Redim Point(3)
Point(0) = "8"
Point(1) = "2"
Point(2) = "65"
Point(3) = "68"
ret = SapModel.AreaObj.AddByPoint(4, Point, Name)
ret = SapModel.View.RefreshView(0, False)
EtabsObject.ApplicationExit(False)
SapModel = Nothing
EtabsObject = Nothing
End Sub
See Also