0

No signature of method, mixed language script

asked 2010-06-17 13:23:02 +0800

eptx gravatar image eptx
130 3

Can someone help me understand the workings of mixed languages (java/groovy) in a page. Specifically, the interpreter is not finding methods...giving an error like:

No signature of method: Script5.doOk() is applicable for argument types: () values: []
Possible solutions: dump(), wait(), run(), run(), any(), wait(long)

Code...
<?page zscriptLanguage="Groovy"?>
<zk>
<zscript language="java">

void doOk() {
Messagebox.show("ENTER key is pressed", "OK", Messagebox.OK, Messagebox.EXCLAMATION);
inp.focus();
}

</zscript>
<zscript language="Groovy">
def doCtrlKey() {
Messagebox.show(event.getKeyCode()+" is pressed", "CtrlKey", Messagebox.OK, Messagebox.EXCLAMATION)
inp.focus()
}

</zscript>
<panel id="panel" title="CMIS Web, ZK"
border="normal" sclass="p-vista">

<toolbar id="tb" sclass="vista" height="20px" align="end">
<toolbarbutton image="/img/volumn.gif"
onClick='alert("Volumn")' />
<toolbarbutton label="12:55 PM"
onClick='alert("time")' />
</toolbar>
<panelchildren>
<hbox>
<tabbox >
<tabs>
<tab label="Tab 1" closable="true"/>
<tab label="Tab 2" closable="true"/>
<tab label="Tab 3" closable="true"/>
<tab label="Tab 4" closable="true"/>
<tab label="Tab 5" closable="true"/>
</tabs>

<tabpanels>
<tabpanel>
<vbox>
<grid fixedLayout="true" width="400px">
<rows>
<row>
Password
<textbox id="inp" onOK="doOk()" onCancel="doCancel()" ctrlKeys="^a^b#f2" onCtrlKey="doCtrlKey()" type="password" value="123456789" width="150px" />
</row>
</rows>
</grid>
</vbox>
</tabpanel>
</tabpanels>
</tabbox>
</hbox>
</panelchildren>
</panel>

<zscript language="java">
{
void doCancel() {
Messagebox.show("ESC key is pressed", "CANCEL", Messagebox.OK, Messagebox.EXCLAMATION);
inp.focus();
}
}
</zscript>

</zk>

delete flag offensive retag edit
Be the first one to reply this discussion!
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow

RSS

Stats

Asked: 2010-06-17 13:23:02 +0800

Seen: 279 times

Last updated: Jun 17 '10

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More