C# Solidworks二次开发:枚举应用实战(第十二讲)

发布于:2024-05-04 ⋅ 阅读:(41) ⋅ 点赞:(0)

大家好,今天还是继续介绍我们的枚举应用系列。

下面是今天要介绍的枚举:

(1)第一个为swsSpotWeldConnectorError_e,这个枚举的含义为点焊接头错误,下面是官方的具体枚举值:

Member Description
SpotWeldConnectorErrorSelectVerticesOrDatumPoint 7 = Select vertices or a datum point
swsSpotWeldConnectorErrorBodyExcludedFromAnalysis 16 = Selected entity is on a body excluded from analysis
swsSpotWeldConnectorErrorEmptyArray 14 = Array for spot-weld entity is empty
swsSpotWeldConnectorErrorGapTooBig 10 = Current gap between the spot-weld faces is greater than the recommended 3 mm
swsSpotWeldConnectorErrorHasRemoteMass 15 = Spot-weld connector has a remote mass
swsSpotWeldConnectorErrorInvalidArray 13 = Invalid array
swsSpotWeldConnectorErrorInvalidMesh 1 = Invalid mesh
swsSpotWeldConnectorErrorInvalidStudy 3 = Invalid study
swsSpotWeldConnectorErrorNonlinearStudyPartDocument 2 = Study type equals nonlinear and document type equals part
swsSpotWeldConnectorErrorNullDispatch 4 = NULL dispatch passed as argument
swsSpotWeldConnectorErrorPlanesNotParallel 8 = Planes are not parallel
swsSpotWeldConnectorErrorPlanesTouching 9 = Planes touching
swsSpotWeldConnectorErrorPostWeldInvalidPoints 12 = Post weld invalid points
swsSpotWeldConnectorErrorSelectAssemblyDocument 5 = Select an assembly document
swsSpotWeldConnectorErrorSelectDatumPoints 11 = Select datum points for spot weld
swsSpotWeldConnectorErrorSelectFace 6 = Select a face
swsSpotWeldConnectorErrorSuccessful 0 = Successful

(2)第二个为swsTopologyStudy_DisplacementConstraintErrors_e,这个枚举的含义为拓扑研究位移约束结果代码,下面是官方的具体枚举值:

Member Description
swsTopoDispErrCode_CannotSetVertex 10 = SetVertex is available only when LocationOption = swsTopologyStudyDisplacementConstraintLocationOption_e.swsTopologyDisplacementConstraintLocationOption_UserDefine
swsTopoDispErrCode_ConstraintNotFound 17 = Constraint does not exist
swsTopoDispErrCode_CoordinateSysInvalidOption 14 = Option must be in swsTopologyStudyDisplacementCoordinateSysOption_e
swsTopoDispErrCode_CoordinateSysInvalidSelection 15 = Wrong coordinate system dispatch was passed
swsTopoDispErrCode_CoordinateSysNAError 13 = SetCoordinateSystem is available only when SetCoordinateSystemPreference sets NCSPreference = swsTopologyStudyDisplacementCoordinateSysOption_e.swsTopologyDisplacementCoordinateSysOption_UserDefine
swsTopoDispErrCode_CoordinateSysNotSelected 16 = Coordinate system has not been set
swsTopoDispErrCode_InvalidArray 18 = Invalid input array
swsTopoDispErrCode_InvalidComparator 7 = Input comparator must be in swsTopologyStudyConstraintComparator_e
swsTopoDispErrCode_InvalidComponent 4 = Component type must be in swsTopologyStudyDisplacementComponentType_e
swsTopoDispErrCode_InvalidConstraintValuationOption 5 = Valuation option must be in swsTopologyStudyConstraintValuationOption_e
swsTopoDispErrCode_InvalidConstraintValue 2 = Input value contains invalid characters
swsTopoDispErrCode_InvalidLocationOption 11 = Location option must be in swsTopologyDisplacementConstraintLocationOption_e
swsTopoDispErrCode_InvalidSelectionForVertex 9 = Wrong vertex dispatch has been passed
swsTopoDispErrCode_InvalidUnit 6 = Input unit must be in swsLinearUnit_e
swsTopoDispErrCode_InvalidVertexCount 12 = You cannot define this displacement constraint when SetLocationPreference sets NLocationPreference = swsTopologyStudyDisplacementConstraintLocationOption_e.swsTopologyDisplacementConstraintLocationOption_UserDefine and vertex count != 1
swsTopoDispErrCode_LessThanEqualToZeroConstraintValue 3 = Less than or equal to zero value is invalid
swsTopoDispErrCode_SetOperationNotSupported 1 = BeginEdit must be called before setting values
swsTopoDispErrCode_Success 0
swsTopoDispErrCode_UnitNotAvailable 8 = SetUnit is available only when SetValuationPreference sets NValuationOption = swsTopologyStudyConstraintValuationOption_e.swsTopologyConstraintValuationOption_AbsValue

(3)第三个为swsTopologyStudyError_e,这个枚举的含义为拓扑研究结果代码,下面是官方的具体枚举值:

Member Description
swsTopoErrCode_CannotCreatFOSIfStressAlrdyPrsnt 18 = Factor of Safety constraint cannot be created if a stress constraint is present
swsTopoErrCode_CannotCreatStressIfFOSAlrdyPrsnt 19 = Stress constraint cannot be created if a Factor of Safety constraint is present
swsTopoErrCode_ConstraintDefinitionLimitReached 11 = No more than seven constraints can be defined
swsTopoErrCode_ConstraintNotFound 9
swsTopoErrCode_DefaultConstraintCannotBeRemoved 10
swsTopoErrCode_InvalidGoalType 2
swsTopoErrCode_ManufacturingControlNotFound 12
swsTopoErrCode_MaximizeStiffnessGoalHasNotBeenSet 5
swsTopoErrCode_MinimizeMassGoalHasNotBeenSet 4
swsTopoErrCode_MinimizeMaximumDisplacementGoalHasNotBeenSet 6
swsTopoErrCode_NoGoalHasBeenSet 3
swsTopoErrCode_OnlyOneDemoldControlCanBeDefined 14
swsTopoErrCode_OnlyOneDisplacementConstraintWithAutoDefineCanBeDefined 8
swsTopoErrCode_OnlyOneFOSConstraintCanBeDefined 21
swsTopoErrCode_OnlyOneFrequencyConstraintCanBeDefined 16
swsTopoErrCode_OnlyOneMassConstraintCanBeDefined 7
swsTopoErrCode_OnlyOneStressConstraintCanBeDefined 20
swsTopoErrCode_OnlyOneSymmetryControlCanBeDefined 15
swsTopoErrCode_OnlyOneThicknessControlCanBeDefined 13
swsTopoErrCode_SetOperationNotSupported 17 = BeginEdit must be called before setting any values
swsTopoErrCode_Success 0
swsTopoErrCode_TopologyStudyManagerIsNotInitialized 1

本篇文章要介绍的就是这么多,我们下篇文章再见。


网站公告

今日签到

点亮在社区的每一天
去签到