Hi All,
I am having a problem in getting exception messages from exception in
onFailure method.

My services are like

//Client Side
public String getName(int id) throws ClientException;

public String getName(int id,AyncCallback) throws ClientException;

//Server Side
public String getName(int id) throws ClientException
{
   ...
   ..
   //on some condition i am throwing ClientException
   throw new  ClientException("You can not do this operation");
}


Now onFailure method i just want to pop this error message in alert;

So
void onFailure(Throwable t)
{
  Window.alert(t.toString);// This line gives me
com.app.exceptions.ClientException which is my class.
  Window.alert(t.getMessage);// this line gives me null
  Window.alert(t.getLocalizedMessage);// this line gives me null
}

So is there any way to get the error message which  i put into
ClientException at server side.

Thanks in advance,
Ravi


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to