8、Property可以添加的选项有三种:Add Property、Add Structure Property、Add List Property
例:FCIProcess_callobject就是Property
(1) Property的属性:
Is Variable:是否是变量
Variable Type:变量类型
In Out Type:是出参还是入参
Is Required:是不是必填
Default Value:默认值
Initial Code:初始化代码 是JetCode
Property Restrist:类型有string、number、boolean、enum
String的属性:Minimum length字符最小长度,Maximum Length:字符最大长度
Number的属性:Minimum Value:最小值 Maximum Value:最大值
Enum的属性:可以添加删除枚举
(1) Structure Property的属性:
(1) List Property的属性:
列表的类型要跟Structure对应就是Refer To
在这个页面可以添加的选项有:Text、combobox、radio、checkbox、
table viewer、treeviewer、sructdialog、externd control、
一般常用的就是text和treeviewer
下图是treeviewer的属性
Refer to 是关联到哪个变量这里是入参
Is Enbalbe:是否可用如果是false在图元里就不能添加参数
Height:图元展现的高度
11、点击Exits
12、点击Jet Editor进入Jet Code编辑
Jet代码结构
Include
<cpp_block:addInclude>#include "main_cpx.h"</cpp_block:addInclude>
Param declare
<cpp_block:createVariable name="parameter0" type="ENIP::TInt4"/>
Initial in paramters
<cpp_block:initialize>
Invoke method
<cpp_block:invokeStateMachineMethod>
Receive out parameter
<c:setVariable select="cppGetPropertyValue('parameter1',true())"var="parameter1"/>