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
eaoliver
Posts: 205
Registered: ‎07-14-2008
My Device: 7230, 8700, 8820, 9000

Acquire local IP address

I'm trying to acquire the IP address of the WLAN interface.  I see that I can retrieve the local address using the UDPDatagramConnection class; however,  openning a socket to retrieve the local IP address doesn't seem very efficient. 

 

Is there an alternative method to retrieving the local IP address that I am missing?

 

Earl

Earl Oliver
Please use plain text.
Developer
jhaehnle
Posts: 238
Registered: ‎08-26-2008
My Device: Not Specified

Re: Acquire local IP address

Hi,

 

public static byte[] getIPAddress(int apnId) in Class RadioInfo??

 

Regards,

Jochen

Please use plain text.
Developer
eaoliver
Posts: 205
Registered: ‎07-14-2008
My Device: 7230, 8700, 8820, 9000

Re: Acquire local IP address

I saw that also, but I'm pretty sure it's for the cellular network only.  I'm not sure what the apnid is for WiFi or if it's even applicable.  The developer documentation seems pretty vague in this area.

 

Earl

Earl Oliver
Please use plain text.