macro_command main() 
short a[3],b[3],p=1 //短整形,一个字,16BIT +-32767 a 变量名 
int k,l,password,m,n,z,w //定义多个变量类型 32BIT双整形(双字) 
bool key=true,key2=false //bool位 0 1 
GetData(password, "本机 触摸屏", LW, 300, 1) //停机画面密码输入 ,将LW300赋值给PASSWORD 
GetData(z, "本机 触摸屏", RW, 1000, 1) // time-1 code ,将RW1000赋值给Z,密码设定值 
GetData(a[0], "本机 触摸屏", RW, 8, 3) // date ,将设定日期RW 8 9 10 3个设定值赋值给A 
GetData(b[0], "本机 触摸屏", LW, 9020, 3) // now ,将即时时钟LW 9020 9021 9022 3个时钟赋值给B 
if a[2]>b[2] then //设定值>时钟时然后 
SetData(key, "本机 触摸屏", RW_Bit, 0, 1) // open window 打开窗口 
else if a[2]==b[2] and a[1]>b[1] then //然后 
SetData(key, "本机 触摸屏", RW_Bit, 0, 1) // open window 打开窗口 
else if a[2]==b[2] and a[1]==b[1] and a[0]>b[0]then 
SetData(key, "本机 触摸屏", RW_Bit, 0, 1) // open window 
end if 
if password==z then //
SetData(key2, "本机 触摸屏", RW_Bit, 0, 1) // close window 关闭窗口 
SetData(key2, "本机 触摸屏", RW_Bit, 10, 1) // end this time  ,关闭时间
end if 
end macro_command
请教一下楼主,PLC控制中LW0 是通过哪个语句去控制画面切换的,