我在某一桢上加lingo如下:
global optwin,optwin1
on exitFrame me
go to the frame +1
optwin=window("sss")
optwin.visible=true
optwin.title = "sss"
optwin.windowtype = 2
optwin.filename ="sss"
optwin.titlevisible=false
set a=((the deskTopRectList[1][3])/2.00)-100
set b=((the deskTopRectList[1][4])/2.00)-50
trect=optwin.rect
tw=trect[3]-trect[1]
th=trect[4]-trect[2]
optwin.rect=rect(a-tw/2.0,b-th/2.0,a+tw/2.0,b+th/2.0)
end
调入一个maiw,我在电影加入movie sprite
global optwin
on mouseUp me
if optwin=window("sss") then
forget optwin
updatestage
else
nothing
updatestage
end if
updatestage
end
当在miaw窗口以外单激时关闭miaw
以上程序都ok
但我想在不同的桢上重复地调入不同的miaw
于是我在另一桢上加入以下代码:
global optwin,optwin1
on exitFrame me
go to the frame +1
optwin1=window("aaa")
optwin1.visible=true
optwin1.title = "aaa"
optwin1.windowtype = 2
optwin1.filename ="aaa"
optwin.titlevisible=false
set a=((the deskTopRectList[1][3])/2.00)-100
set b=((the deskTopRectList[1][4])/2.00)-50
trect=optwin1.rect
tw=trect[3]-trect[1]
th=trect[4]-trect[2]
optwin1.rect=rect(a-tw/2.0,b-th/2.0,a+tw/2.0,b+th/2.0)
end
仅"sss"变成"aaa"
原来的movie sprite变为:
global optwin
on mouseUp me
if optwin=window("sss") then
close optwin
forget optwin
updatestage
else
nothing
updatestage
if optwin1=window("aaa") then
closeoptwin1
forget optwin1
updatestage
else
nothing
updatestage
end if
end if
end
这是我在D的编辑状态中运行一切ok,但关闭D后用exe调用此dir时就报错说次dir已打开!
请问大侠们
1、次现象是何缘故?
2、对与调用多个miaw还有什么好方法吗?
多谢各位!!!
:confused: :confused: :confused: :confused: