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

devtools/2024/10/18 18:15:49/

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

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

(1)第一个为swsUserPreferenceIntegerValue_e,这个枚举的含义为用户偏好整数值,下面是官方的具体枚举值:

MemberDescription
swsColorChartColorOptionBaseChartColorNumber23 = Get or set the number of colors in the color chart; corresponds to Simulation > Options > Default Options > Plot > Color Chart > Color Options > No of chart colors
swsColorChartColorOptionChartColorNumber22 = Get or set the user-defined number of colors in the color chart; corresponds to Simulation > Options > Default Options > Plot > Color Chart > Color Options > User defined
swsColorChartColorOptionLegendType24 = Get or set the color legend type as defined in swsColorChartOptionLegendTypeValue_e; corresponds to Simulation > Options > Default Options > Plot > Color Chart > Color Options > (Default, Rainbow, Gray scale, User Defined)
swsColorChartColorOptionvonMisesColorValue27 = Get or set the color for values above yield for vonMises plots; corresponds to Simulation > Options > Default Options > Plot > Color Chart > Color Options > Specify color for values above yield for vonMises plot
swsColorChartNumberFormatLegendPrecision25 = Get or set the number of decimal places for precision of number formats; corresponds to Simulation > Options > Default Options > Plot > Color Chart > Number format > No. of decimal places:
swsColorChartNumberFormatOption21 = Get or set the number format as defined in swsColorChartNumberFormatOptionValue_e; corresponds to Simulation > Options > Default Options > Plot > Color Chart > Number format > (Scientific, Floating, or General)
swsColorChartNumberFormatUseDiffNoFormatOption26 = Get or set which notation other than scientific to use for small numbers as defined in swsColorNumberFormatUseDiffNumberFormatOptionValue_e; corresponds to Simulation > Options > Default Options > Plot > Color Chart > Number format > Scientific > Use different number format for small numbers (0.001 < |x| < 1000) > (Floating or General)
swsColorChartPosition3 = Get or set the position of the color bar as defined in swsColorChartPositionValue_e; corresponds to Simulation > Options > Default Options > Plot > Color Chart > Position > (Predefined positions or user defined)
swsColorChartPositionUserDefinedXValue18 = Get or set the color bar's horizontal distance from the left of the graphics area as a percentage of the width of the window; corresponds to Simulation > Options > Default Options > Plot > Color Chart > Position > User defined > Horizontal from left:
swsColorChartPositionUserDefinedYValue19 = Get or set the color bar's vertical distance from the top of the graphics area as a percentage of the height of the window; corresponds to Simulation > Options > Default Options > Plot > Color Chart > Position > User defined > Vertical from top:
swsColorChartWidthOption20 = Get or set the color chart width as defined in swsColorChartWidthOptionValue_e; corresponds to Simulation > Options > Default Options > Plot > Color Chart > Width
swsDefaultResultFolder1 = Get or set the results folder option as defined in swsResultFolderValue_e; corresponds to Simulation > Options > Default Options > Results > Results folder > (SOLIDWORKS document folder or User defined)
swsDefaultSolverValue0 = Get or set the default solver as defined in swsSolverType_e; corresponds to Simulation > Options > Default Options > Results > Default Solver > (Automatic, Direct sparse, or FFEPlus) 
swsEMailType30
swsPlotBoundaryOptionMeshColor9 = Get or set the mesh color for boundaries (see Remarks); corresponds to Simulation > Options > Default Options > Plot > Settings options > Boundary options > Mesh > color select box
swsPlotBoundaryOptionModelColor29 = Get or set the model color for boundaries (see Remarks); corresponds to Simulation > Options > Default Options > Plot > Settings options > Boundary options > Model
swsPlotBoundaryOptionTranslucentSingleColorSetting8 = Get or set the translucent color for boundaries (see Remarks); corresponds to Simulation > Options > Default Options > Plot > Settings options > Boundary options > Translucent (Single color) > color select box
swsPlotDeformedShapeOptionSetSuperImposeOption16 = Get or set the translucent color option for superimposing the model on deformed shape as defined in swsPlotDeformedShapeOptionSuperImposeValue_e; corresponds to Simulation > Options > Default Options > Plot > Deformed shape options > Show results on deformed shape > Superimpose model on deformed shape > Translucent (part colors or single color)
swsPlotDeformedShapeOptionSetting12 = Get or set how to show deformed shape results as defined in swsPlotDeformedShapeOptionValue_e; corresponds to Simulation > Options > Default Options > Plot > Deformed shape options > Show results on undeformed shape or Show results on deformed shape
swsPlotDeformedShapeOptionTranslucentColor28 = Get or set the translucent color for superimposing the model on deformed shape (see Remarks);  corresponds to Simulation > Options > Default Options > Plot > Deformed shape options > Show results on deformed shape > Superimpose model on deformed shape > Translucent (single color) > color select box
swsPlotDeformedShapeResultOther15 = Get or set the deformation scale factor for all other studies as defined in swsPlotDeformedShapeOptionScaleFactorOtherValue_e; corresponds to Simulation > Options > Default Options > Plot > Deformed shape options > Show results on deformed shape > Deformation scale factor for: > all other studies: > Automatic or True(1.0)
swsPlotDeformedShapeResultScaleContact13 = Get or set the deformation scale factor for all studies with "No penetration" contact as defined in swsPlotDeformedShapeOptionScaleFactorContactValue_e; corresponds to Simulation > Options > Default Options > Plot > Deformed shape options > Show results on deformed shape > Deformation scale factor for: > all studies with "No penetration" contact: > Automatic or True(1.0)
swsPlotDeformedShapeResultScaleLarge14 = Get or set the deformation scale factor for studies with the "Large displacement" option as defined in swsPlotDeformedShapeOptionScaleFactorLargeDispValue_e; corresponds to Simulation > Options > Default Options > Plot > Deformed shape options > Show results on deformed shape > Deformation scale factor for: > studies with the "Large displacement" option: > Automatic or True(1.0)
swsPlotSettingsBoundaryOption5 = Get or set the boundary option as defined in swsPlotBoundarySettingsOptionValue_e; corresponds to Simulation > Options > Default Options > Plot > Settings options > Boundary options
swsPlotSettingsFringeOption4 = Get or set the fringe option as defined in swsPlotFringeSettingsOptionValue_e; corresponds to Simulation > Options > Default Options > Plot > Settings options > Fringe options
swsPlotShowExcludedBodiesOption6 = Get or set the translucent color option for excluded bodies as defined in swsPlotShowExcludedBodiesOptionValue_e; corresponds to Simulation > Options > Default Options > Plot > Settings options > Show excluded bodies > Translucent (Single color or Part colors)
swsPlotShowExcludedBodyTranslucentSingleColor10 = Get or set the translucent color for all excluded bodies (see Remarks);  corresponds to Simulation > Options > Default Options > Plot > Settings options > Show excluded bodies > Translucent (Single color) > color select box
swsPlotShowHiddenBodiesOption7 = Get or set the translucent color option for hidden bodies as defined in swsPlotShowHiddenBodiesOptionValue_e; corresponds to Simulation > Options > Default Options > Plot > Settings options > Show hidden bodies > Translucent (Single color or Part colors)
swsPlotShowHiddenBodyTranslucentSingleColor11 = Get or set the translucent color for all hidden bodies (see Remarks); corresponds to Simulation > Options > Default Options > Plot > Settings options > Show hidden bodies > Translucent (Single color) > color select box
swsReportPublishOption2 = Get or set the report folder location as defined in swsReportFolderValue_e; corresponds to Simulation > Options > Default Options > Report > Report publish options > Report folder
swsReportPublishOptionReportFolderUserDefinedPath17

(2)第二个为swsUserPreferenceToggle_e,这个枚举的含义为用户首选项切换值,下面是官方的具体枚举值:

MemberDescription
swsAverageStressesAtMidnodes17 = Get or set whether to average stresses at mid-nodes; corresponds to Simulation > Options > Default Options > Results > Average stresses at mid-nodes (high-quality solid mesh only)
swsColorChartColorNoOfChartColorFlip13 = Get or set whether to flip the chart colors; corresponds to Simulation > Options > Default Options > Plot > Color Chart > Color options > Flip
swsColorChartColorSpecifyColorForvonMisesPlot14 = Get or set whether to specify color for values above yield for vonMises plot; corresponds to Simulation > Options > Default Options > Plot > Color Chart > Color options > Specify color for values above yield for vonMises plot
swsColorChartDetails11 = Get or set whether to display plot details; corresponds to Simulation > Options > Default Options > Plot > Color Chart > Display plot details 
swsColorChartDisplay10 = Get or set whether to display plot details; corresponds to Simulation > Options > Default Options > Plot > Color Chart > Display color charts 
swsColorChartNumberFormatUseDifferentNumberFormat12 = Get or set whether to use a different number format for small numbers; corresponds to Simulation > Options > Default Options > Plot > Color Chart > Number format > Scientific > Use different number format for small numbers (0.001 < |x| < 1000)
swsEMailAuthentication16 = Get or set whether my server requires authentication; corresponds to Simulation > Options > System Options > Email Notification Settings > My server requires authentication
swsLoadAllStudies_e15 = Get or set whether to load all Simulation studies when opening a model; corresponds to Simulation > Options > System Options > General > Load all Simulation studies when opening a model. (requires more time to open a model)
swsPlotAnnotationShowMaxValue5 = Get or set whether to show the maximum value annotation in plots; corresponds to Simulation > Options > Default Options > Plot > Annotation and range > Show maximum value annotation
swsPlotAnnotationShowMinValue4 = Get or set whether to show the minimum value annotation in plots; corresponds to Simulation > Options > Default Options > Plot > Annotation and range > Show minimum value annotation
swsPlotAnnotationShowRangeBasedOnShowCompOnly6 = Get or set whether to show range based on shown components only in plots; corresponds to Simulation > Options > Default Options > Plot > Annotation and range > Show range based on shown components only
swsPlotDeformedShapeOptionSuperImposeModelOnDeformedShape9 = Get or set whether to superimpose model on deformed shape in plots; corresponds to Simulation > Options > Default Options > Plot > Deformed shape options > Show rsults on deformed shape > Superimpose model on deformed shape
swsPlotShowExcludedBodies7 = Get or set whether to show excluded bodies in plots; corresponds to Simulation > Options > Default Options > Plot > Settings options > Show excluded bodies
swsPlotShowHiddenBodies8 = Get or set whether to show hidden bodies in plots; corresponds to Simulation > Options > Default Options > Plot > Settings options > Show hidden bodies
swsResultFolderKeepTempDataBase1 = Get or set whether to keep temporary database files in results folder; corresponds to Simulation > Options > Default Options > Results > Results folder > Keep temporary database files
swsResultFolderUnderSubFolder0 = Get or set whether to set results folder under a SOLIDWORKS document folder sub folder; corresponds to Simulation > Options > Default Options > Results > Results folder > SOLIDWORKS document folder > Under sub folder
swsShowReportOnPublish3 = Get or set whether to show the report when it's published; corresponds to Simulation > Options > Default Options > Report > Report publish options > Show report on publish
swsTrendTrackerBackUpModelsRestoreIteration2 = Get or set whether to back up models for Restore to Iteration; corresponds to Simulation > Options > Default Options > Results > Trend Tracker > Backup models for Restore to Iteration

(3)第三个为swsWindowsBasicColors_e,这个枚举的含义为windows基本色,下面是官方的具体枚举值:

MemberDescription
swsAqua16776960
swsBlack0
swsBlue16711680
swsCoral4227327
swsCyan16777088
swsDarkBlue4194304
swsDarkGreen4210688
swsDarkOliveGreen16384
swsDarkPurple4194368
swsDarkRed4194432
swsDeepGray64
swsDeepSkyBlue12645680
swsDodgerBlue16744448
swsGray8421504
swsGreen32768
swsGreenYellow65408
swsIndigo8388672
swsKhaki4227200
swsLawnGreen4259584
swsLightRed8421631
swsLightSalmon4210816
swsLightSeaGreen8421440
swsLightYellow8454143
swsLime65280
swsMagenta16711935
swsMaroon128
swsMediumPurple12615808
swsMidnightBlue10485760
swsNavy8388608
swsOlive32896
swsOrange33023
swsPaleGreen8454016
swsPlum12615935
swsPurple8388736
swsRed255
swsRoyalBlue8404992
swsSapGreen4227072
swsSgiBeet16711808
swsSgiSalmon8388863
swsSgiSlateBlue16744576
swsSilver12632256
swsSpringGreen8453888
swsTan16512
swsTeal8421376
swsViolet16744703
swsWhite16777215
swsYellow65535

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


http://www.ppmy.cn/devtools/36355.html

相关文章

R语言计算特定列的和(自备)

R语言长款数据转换&#xff08;自备&#xff09;_r语言宽数据转换成长数据-CSDN博客 数据 rm(list ls()) library(ggplot2) library(ggpubr) library(cowplot) data <- iris##鸢尾花数据集 #[1] "Sepal.Length" "Sepal.Width" "Petal.Length&…

FastAPI - Tortoise ORM 数据库基础操作

文章目录 1. 安装 Tortoise ORM2. 定义模型3. 初始化数据库连接4. 数据库操作4.1 创建数据4.2 查询数据4.3 更新数据4.4 删除数据 5. 使用 Pydantic 模型6. 关闭数据库连接7. fields类相关操作1. fields.IntField2. fields.BigIntField3. fields.SmallIntField4. fields.CharFi…

vue3—项目创建

背景 初次学习vue3&#xff0c;需要从项目创建开始。 步骤 打开cmd命令行&#xff0c;进入项目存放目录下&#xff0c;执行创建命令&#xff1a; npm create vuelatest 这一指令将会安装并执行 create-vue&#xff0c;它是 Vue 官方的项目脚手架工具。你将会看到一些诸如 …

浙里办开发相关问题

1.获取相册图片和拍照的方法 ZWJSBridge.chooseImage({upload: true,}).then((result) > {try {result.picPath.map((item) > {photoList.unshift(item)})} catch (error) {}}) 相关API import { createElement, useState } from rax; import View from rax-view; impo…

计算机毕业设计 | springboot+vue小米商城 米家购物网站管理系统

1&#xff0c;项目背景 国家大力推进信息化建设的大背景下&#xff0c;城市网络基础设施和信息化应用水平得到了极大的提高和提高。特别是在经济发达的沿海地区&#xff0c;商业和服务业也比较发达&#xff0c;公众接受新事物的能力和消费水平也比较高。开展商贸流通产业的信息…

鸿蒙内核源码分析(事件控制篇) | 任务间多对多的同步方案

官方概述 先看官方对事件的描述. 事件&#xff08;Event&#xff09;是一种任务间通信的机制&#xff0c;可用于任务间的同步。 多任务环境下&#xff0c;任务之间往往需要同步操作&#xff0c;一个等待即是一个同步。事件可以提供一对多、多对多的同步操作。 一对多同步模型…

【统计推断】-01 抽样原理之(六):三个示例

目录 一、说明二、处理有限的、大尺度的母体抽样三、非参数的估计四、连续母体抽样技巧--分箱 一、说明 对于抽样问题&#xff0c;前几期文章都是理论探讨。本篇给出若干示例&#xff0c;展现具体的情况下&#xff0c;面对数据&#xff0c;如何给出处理策略。 二、处理有限的…

白酒:白酒香型的国际化推广与市场接受度分析

云仓酒庄的豪迈白酒一直有在白酒香型的国际化推广。随着中国白酒市场的不断扩大和国际化的趋势&#xff0c;了解白酒香型的国际接受度和推广策略对于酒厂和整个行业都具有重要意义。 首先&#xff0c;国际化推广需要深入了解国际市场的需求和消费者偏好。不同国家和地区的消费者…