问题具体情况:
7 ?/ @5 y. Y0 A5 v9 {3 w
+ W }0 Z9 t! U2 D h4 o; |' I一共有三种产品分别存放在三个货架上,三个货架均连接在一个暂存区上,模型中有一张动态生成的全局表,通过读取表中的数值,打开某一个端口;我试着建立了中间端口,然后在暂存区的进入触发器中写下了如下代码:
% j# {7 [! a- C V# R6 s
Y3 J: J! Z- E( e* Z gif(gettabelnum("全局表",getoutput(current)+1,6) == 1)7 \% r" _- W* [. K. @. }
{6 O. L2 [; Q: D$ `/ e, W% @
openinput(centerobject(current,1));centerobject(current,1);
8 |: J. q" h2 U( I% K}+ Y- G; y4 V9 F4 v5 [3 h
else if (gettabelnum("全局表",getoutput(current)+1,6) == 2)
, e! @1 @7 K' t2 F7 k O{
. U# e5 @) e# j3 @7 g7 eopeninput(centerobject(current,2));centerobject(current,2);
* H. L. n; ?" W I, Y}+ O& v% P/ H7 Z: `' G
else if (gettabelnum("全局表",getoutput(current)+1,6) == 3) N" l& L) {0 n* A
{
" L" c( k j+ H* @5 ~0 }/ eopeninput(centerobject(current,23));centerobject(current,3);
$ S9 {- n4 [! m% \) y" ?/ C}
% U8 ^# `! G8 M- @, \3 G. m( Y7 r2 p& c q( ^- Y
问题 模型在运行很短时间后就停下了,不知道问题到底出在哪里,求前辈们指点一下。 |