Hide Table of Contents
AddSelectedBaseExcitation Method (ICWLoadsAndRestraintsManager)

Applies a base excitation to the specified restraint along the specified directions for dynamic studies.

.NET Syntax

Visual Basic (Declaration) 
Function AddSelectedBaseExcitation( _
   ByVal NType As System.Integer, _
   ByVal SFixtureName As System.String, _
   ByVal NUnits As System.Integer, _
   ByVal BDir1 As System.Integer, _
   ByVal DVal1 As System.Double, _
   ByVal BDir2 As System.Integer, _
   ByVal DVal2 As System.Double, _
   ByVal BDir3 As System.Integer, _
   ByVal DVal3 As System.Double, _
   ByRef ErrorCode As System.Integer _
) As CWBaseExcitation
Visual Basic (Usage) 
Dim instance As ICWLoadsAndRestraintsManager
Dim NType As System.Integer
Dim SFixtureName As System.String
Dim NUnits As System.Integer
Dim BDir1 As System.Integer
Dim DVal1 As System.Double
Dim BDir2 As System.Integer
Dim DVal2 As System.Double
Dim BDir3 As System.Integer
Dim DVal3 As System.Double
Dim ErrorCode As System.Integer
Dim value As CWBaseExcitation
value = instance.AddSelectedBaseExcitation(NType, SFixtureName, NUnits, BDir1, DVal1, BDir2, DVal2, BDir3, DVal3, ErrorCode)
CWBaseExcitation AddSelectedBaseExcitation( 
   System.int NType,
   System.string SFixtureName,
   System.int NUnits,
   System.int BDir1,
   System.double DVal1,
   System.int BDir2,
   System.double DVal2,
   System.int BDir3,
   System.double DVal3,
   out System.int ErrorCode
CWBaseExcitation^ AddSelectedBaseExcitation( 
&   System.int NType,
&   System.String^ SFixtureName,
&   System.int NUnits,
&   System.int BDir1,
&   System.double DVal1,
&   System.int BDir2,
&   System.double DVal2,
&   System.int BDir3,
&   System.double DVal3,
&   [Out] System.int ErrorCode


Type of excitation as defined in swsBaseExcitationType_e
Model entity to which the restraint is applied 

If NType is ... Then units are as defined in ...
swsBaseExcitationType_e.swsBaseExcitationType_Displacement swsLinearUnit_e
swsBaseExcitationType_e.swsBaseExcitationType_Velocity swsVelocityUnit_e
swsBaseExcitationType_e.swsBaseExcitationType_Acceleration swsAccelerationUnit_e

1 to add excitation along plane direction 1, 0 to not
Excitation along plane direction 1 (see Remarks)
1 to add excitation along plane direction 2, 0 to not
Excitation along plane direction 2 (see Remarks)
1 to add excitation along normal to plane, 0 to not
Excitation along normal to the plane (see Remarks)

Error code as defined in swsRestraintError_e

Return Value



Set negative values in DVal1, DVal2, and DVal3 to indicate reverse directions.

If this is a random vibration dynamic study, then DVal1, DVal2, and DVal3 are the Power Spectral Densities of the specified NType.


See Also


SolidWorks Simulation API 2012 SP0

Provide feedback on this topic

SOLIDWORKS welcomes your feedback concerning the presentation, accuracy, and thoroughness of the documentation. Use the form below to send your comments and suggestions about this topic directly to our documentation team. The documentation team cannot answer technical support questions. Click here for information about technical support.

* Required

Subject:   Feedback on Help Topics
Page:   AddSelectedBaseExcitation Method (ICWLoadsAndRestraintsManager)
*   I acknowledge I have read and I hereby accept the privacy policy under which my Personal Data will be used by Dassault Systèmes

Print Topic

Select the scope of content to print:


We have detected you are using a browser version older than Internet Explorer 7. For optimized display, we suggest upgrading your browser to Internet Explorer 7 or newer.

 Never show this message again

Web Help Content Version: API Help (English only) 2014 SP05

To disable Web help from within SOLIDWORKS and use local help instead, click Help > Use SOLIDWORKS Web Help.

To report problems encountered with the Web help interface and search, contact your local support representative. To provide feedback on individual help topics, use the “Feedback on this topic” link on the individual topic page.