cPointObjAddCartesian Method |
Adds a point object to a model. The added point object will be tagged
as a Special Point except if it was merged with another point object.
Special points are allowed to exist in the model with no objects
connected to them.
Namespace:
ETABS2016
Assembly:
ETABS2016 (in ETABS2016.dll) Version: 16.0.0.0 (16.0.0.0)
Syntaxint AddCartesian(
double X,
double Y,
double Z,
ref string Name,
string UserName = "",
string CSys = "Global",
bool MergeOff = false,
int MergeNumber = 0
)
Function AddCartesian (
X As Double,
Y As Double,
Z As Double,
ByRef Name As String,
Optional UserName As String = "",
Optional CSys As String = "Global",
Optional MergeOff As Boolean = false,
Optional MergeNumber As Integer = 0
) As Integer
int AddCartesian(
double X,
double Y,
double Z,
String^% Name,
String^ UserName = L"",
String^ CSys = L"Global",
bool MergeOff = false,
int MergeNumber = 0
)
abstract AddCartesian :
X : float *
Y : float *
Z : float *
Name : string byref *
?UserName : string *
?CSys : string *
?MergeOff : bool *
?MergeNumber : int
(* Defaults:
let _UserName = defaultArg UserName ""
let _CSys = defaultArg CSys "Global"
let _MergeOff = defaultArg MergeOff false
let _MergeNumber = defaultArg MergeNumber 0
*)
-> int
Parameters
- X
- Type: SystemDouble
- Y
- Type: SystemDouble
- Z
- Type: SystemDouble
- Name
- Type: SystemString
This is the name that the program ultimately assigns for the point object.
If no userName is specified, the program assigns a default name to the point object.
If a userName is specified and that name is not used for another point,
the userName is assigned to the point; otherwise a default name is assigned to the point.
If a point is merged with another point, this will be the name
of the point object with which it was merged.
- UserName (Optional)
- Type: SystemString
- CSys (Optional)
- Type: SystemString
The name of the coordinate system in which the joint coordinates are defined.
- MergeOff (Optional)
- Type: SystemBoolean
If this item is False, a new point object that is added at the same location
as an existing point object will be merged with the existing point object
(assuming the two point objects have the same MergeNumber) and thus only
one point object will exist at the location.
If this item is True, the points will not merge and two point objects
will exist at the same location.
- MergeNumber (Optional)
- Type: SystemInt32
Two points objects in the same location will merge only if their
merge number assignments are the same. By default all pointobjects
have a merge number of zero.
Return Value
Type:
Int32
Returns zero if the point object is successfully added or merged,
otherwise it returns a nonzero value.
Remarks
ExamplesPublic Sub Example()
Dim SapModel As cSapModel
Dim EtabsObject As cOAPI
Dim ret As Integer = -1
Dim x As Double, y As Double, z As Double
Dim Name As String
Dim MyName 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)
x = 12
y = 37
z = 0
MyName = "A1"
ret = SapModel.PointObj.AddCartesian(x, y, z, Name, MyName)
EtabsObject.ApplicationExit(False)
SapModel = Nothing
EtabsObject = Nothing
End Sub
See Also