-
FEATURED COMPONENTS
First time here? Check out the FAQ!
The below code does not work, and if i remove deferred="true', then it works. Any thing wrong in my code.
<window title="My First Window" border="normal" width="200px">
<zscript deferred="true">
void add(){
alert("Hi");
}
</zscript>
<button onClick="add()" />
</window>
Note: I tested in 3.5.1 and zk 5
I think this is a bug.
I have the same result if I test it in zkdemo, and I already post it in SF.net: zscript deferred attribute was broken
But it seems it works fine if you use it inside a normal zul file, can you test your case in your project for me?
But it seems it works fine if you use it inside a normal zul file, can you test your case in your project for me?
Not sure, when you say normal zul file? I have the above sample code in test.zul file and the zscript method is embedded inside the zul page.
ok. Now I know what the issue is. The fix need some fine tuning.
baiscally, I have more than once zscript in my file. thats why id did not work after the fix. i.e.,
<window title="My First Window" border="normal" width="200px">
<zscript >
void addALert(){
alert("Hi Alert");
}
</zscript>
<zscript deferred="true">
void add(){
alert("Hi");
}
</zscript>
<button onClick="add();addALert()" />
</window>
The below code does not work after the fix. Please verify it.
Thanks. I tried to re-open it. But don't know how to do it.
I saw Henri re-opened it. We will follow it.
FTI: to re-open, just change the status to Open.
Asked: 2010-02-06 11:20:09 +0800
Seen: 628 times
Last updated: Feb 15 '10