一下代码不知是否是楼主的意图所在.
本人调试过了.选择对象时必须选择'实体',属性赋值是成功的.
$$变量声明
ENTITY/ENT(100)
STRING/AA(5,2),BB(5,2),CC(5,2),DD(5,2),EE(5,2),ATT(10,100)
NUMBER/AA1(5),BB1(5),CC1(5),DD1(5),EE1(5)
DATA/AA,'A1','A2','A5','A4','A5'
DATA/BB,'B1','B2','B5','B4','B5'
DATA/CC,'C1','C2','C5','C4','C5'
DATA/DD,'D1','D2','D5','D4','D5'
DATA/EE,'E1','E2','E5','E4','E5'
P10:
CHOOSE/'23423423','111','222','333','444','555',RESP
JUMP/P10:,TRM:,,,T10:,T20:,T30:,T40:,T50:,RESP
T10:
MCHOOSE/'3453534',AA,AA1,RESP
JUMP/T10:,TRM:,,RESP
COU=0
DO/LT10:,I,1,5
IFTHEN/AA1(I)>0
COU=COU+1
ATT(COU)='AAA'+ISTR(I)
COU=COU+1
ATT(COU)=AA(I)
ENDIF
LT10:
JUMP/P20:
T20:
MCHOOSE/'3453534',BB,BB1,RESP
JUMP/T20:,TRM:,,RESP
COU=0
DO/LT20:,I,1,5
IFTHEN/BB1(I)>0
COU=COU+1
ATT(COU)='BBB'+ISTR(I)
COU=COU+1
ATT(COU)=BB(I)
ENDIF
LT20:
JUMP/P20:
T30:
MCHOOSE/'3453534',CC,CC1,RESP
JUMP/T30:,TRM:,,RESP
COU=0
DO/LT30:,I,1,5
IFTHEN/CC1(I)>0
COU=COU+1
ATT(COU)='CCC'+ISTR(I)
COU=COU+1
ATT(COU)=CC(I)
ENDIF
LT30:
JUMP/P20:
T40:
MCHOOSE/'3453534',DD,DD1,RESP
JUMP/T40:,TRM:,,RESP
COU=0
DO/LT40:,I,1,5
IFTHEN/DD1(I)>0
COU=COU+1
ATT(COU)='DDD'+ISTR(I)
COU=COU+1
ATT(COU)=DD(I)
ENDIF
LT40:
JUMP/P20:
T50:
MCHOOSE/'3453534',EE,EE1,RESP
JUMP/T50:,TRM:,,RESP
COU=0
DO/LT50:,I,1,5
IFTHEN/EE1(I)>0
COU=COU+1
ATT(COU)='EEE'+ISTR(I)
COU=COU+1
ATT(COU)=EE(I)
ENDIF
LT50:
P20:
$$MASK/70 $$只选择实体或片体
IDENT/'SELECT A ENTIYS',ENT,CNT,NUM,RESP $$NUM需要放在CNT后面。
JUMP/P20:,TRM:,,RESP
IFTHEN/COU>0
ASATT/ENT(1..NUM),ATT(1..COU)
ENDIF
TRM: $$终止标记.
MESSG/'OK'
halt $$终止命令. |