Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
Developer
Aviator168
Posts: 709
Registered: ‎09-10-2009
My Carrier: Verizon

Re: Trouble sending UDP packets in simulator

You might have incude the local port number in the connection string.

 

This is from the demo. The local port number is 3501 in this case.

 

 _conn = (UDPDatagramConnection)Connector.open("datagram://127.0.0.1:2000;3501");   

Please use plain text.
Developer
Posts: 1,474
Registered: ‎04-14-2009

Re: Trouble sending UDP packets in simulator

In theory, according to javadocs, if you don't specify the local port number, it will be the same as the remote port number. But you never know -- give it a try...

 

Another thing that occurred to me is that in some simulators networking works OK on WiFi only, whereas on others both cellular and WiFI interfaces work fine. So, try WiFi in the simulator.

Please use plain text.