Selects the first entity of the specified type that is intersected by a ray that starts at the specified point and runs parallel to the specified direction vector within the specified radius.
.NET Syntax
Visual Basic (Declaration) | |
---|
Function SelectByRay( _
ByVal WorldX As System.Double, _
ByVal WorldY As System.Double, _
ByVal WorldZ As System.Double, _
ByVal RayVecX As System.Double, _
ByVal RayVecY As System.Double, _
ByVal RayVecZ As System.Double, _
ByVal RayRadius As System.Double, _
ByVal TypeWanted As System.Integer, _
ByVal Append As System.Boolean, _
ByVal Mark As System.Integer, _
ByVal Option As System.Integer _
) As System.Boolean |
Visual Basic (Usage) | |
---|
Dim instance As IModelDocExtension
Dim WorldX As System.Double
Dim WorldY As System.Double
Dim WorldZ As System.Double
Dim RayVecX As System.Double
Dim RayVecY As System.Double
Dim RayVecZ As System.Double
Dim RayRadius As System.Double
Dim TypeWanted As System.Integer
Dim Append As System.Boolean
Dim Mark As System.Integer
Dim Option As System.Integer
Dim value As System.Boolean
value = instance.SelectByRay(WorldX, WorldY, WorldZ, RayVecX, RayVecY, RayVecZ, RayRadius, TypeWanted, Append, Mark, Option) |
C# | |
---|
System.bool SelectByRay(
System.double WorldX,
System.double WorldY,
System.double WorldZ,
System.double RayVecX,
System.double RayVecY,
System.double RayVecZ,
System.double RayRadius,
System.int TypeWanted,
System.bool Append,
System.int Mark,
System.int Option
) |
C++/CLI | |
---|
System.bool SelectByRay(
& System.double WorldX,
& System.double WorldY,
& System.double WorldZ,
& System.double RayVecX,
& System.double RayVecY,
& System.double RayVecZ,
& System.double RayRadius,
& System.int TypeWanted,
& System.bool Append,
& System.int Mark,
& System.int Option
) |
Parameters
- WorldX
- x coordinate of ray start point
- WorldY
- y coordinate of ray start point
- WorldZ
- z coordinate of ray start point
- RayVecX
- x coordinate of ray direction vector
- RayVecY
- y coordinate of ray direction vector
- RayVecZ
- z coordinate of ray direction vector
- RayRadius
- Radius
- TypeWanted
- Type of entities to select as defined in swSelectType_e
- Append
If... |
And if entity is... |
Then... |
True |
Not already selected |
Entity is appended to the current selection list |
|
Already selected |
Entity is removed from the current selection list |
False |
Not already selected |
Current selection is cleared and then the entity is put on the list |
|
Already selected |
Current selection list remains the same |
- Mark
- Value to use as a mark; this value is used by other functions that require ordered selection
- Option
- Selection option as defined in swSelectOption_e (see Remarks)
Return Value
True if the entity is selected, false if not
Example
Remarks
See Also
Availability
SOLIDWORKS 2017 FCS, Revision Number 25.0