Java class undefined problem

View: New views
2 Messages — Rating Filter:   Alert me  

Java class undefined problem

by Deepti Rajoria :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Some parts of this message have been removed. Learn more about Nabble's security policy.
Hi!
       I made a sample application from the examples given.i made a html as in demo example.When i execute it, there is an error of Demo undefined.
      Demo.sayHello(name, function(data) {
     dwr.util.setValue("demoReply", data);
   });
Demo is the java class mapped in dwr.xml file.i have included following javascipts in html
<script type='text/javascript' src='/dwr/engine.js'></script>
<script type='text/javascript' src='/dwr/inteface/Demo.js'></script>
<script type='text/javascript' src='/dwr/util.js'></script>
 
can anybody telll me whats wrong in this.

Re: Java class undefined problem

by stojadinovicp :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Sounds like your missing the Demo creator in dwr.xml?

Something like:
<create creator="new" javascript="Demo">
< param name="class" value="com.bla.Demo" />
<include method="sayHello" />
</create>

You can see what classes and which methods have been defined by going to localhost:xxxx/yourApp/dwr

Pedja

Deepti Rajoria wrote:
I made a sample application from the examples given.i made a html as in demo example.When i execute it, there is an error of Demo undefined.