0

I am calling a web service from blackberry when I try to open a connection using Http Connection it throws uncaught exception.

"Uncaught Exception: Application is not responding: process terminated"

Everything is working fine if I use EVO or WIFI but in my network few services are blocked and URL I am passing in open connection is also blocked.

I am using this code

url="http://mywebservice/"+ PhoneNo + "/" + RegistrationNo+"/" + PinCode;
String URL = url +getConnectionString()+";ConnectionTimeout=20000";
con = (HttpConnection)Connector.open(URL,Connector.READ_WRITE,true);

Please suggest any solution or how can we check that if requested URL is available or blocked?

tshepang
  • 12,111
  • 21
  • 91
  • 136

1 Answers1

0

An educated guess: You are opening connection via EDT - Event Dispatch Thread (main app thread) this thread can not be used for time consuming operations (connection handling in your example). You need to do these tasks on different threads.

dardi
  • 39
  • 4