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

Native Development

Reply
Regular Contributor
Posts: 76
Registered: ‎07-31-2012
My Device: Blackberry
My Carrier: Vodafone
Accepted Solution

Check internet availability

Hi,

 

I need to check whther the device can access internet or not. I tried using QNetworkAccessManager class' networkAccessible property, but it always returns UnknownAccessibility. My device is connected through Wi-Fi only.

What is the best way to find internet accessiblity status?

 

Regards,

Nishant Shah

Developer
Posts: 571
Registered: ‎04-11-2009
My Device: BB 10 Dev Alpha

Re: Check internet availability

Hi,

 

You may like to check this - https://github.com/blackberry/Cascades-Community-Samples/tree/master/LocationDiagnostics

Regards,
Kanak Sony
------------------------------------------------------------------------------------------
http://dodevelopnshare.wordpress.com/ | http://www.linkedin.com/profile/view?id=188131481&trk=tab_pro
Developer
Posts: 654
Registered: ‎02-03-2010
My Device: Z10 LE
My Carrier: Rogers

Re: Check internet availability

HI 


Steven Kader at JaredCo
   Follow me on Twitter    |     Mipixi.com :  Web App for Photo Sharing
Developer
Posts: 194
Registered: ‎11-24-2012
My Device: Dev Alpha B, Bold 9700
My Carrier: NA

Re: Check internet availability

[ Edited ]

Try this link:

https://github.com/blackberry/Cascades-Samples

 

Download and extract the zip (or clone it), and open the LcoationDiagnostics project.

 

Developer
Posts: 654
Registered: ‎02-03-2010
My Device: Z10 LE
My Carrier: Rogers

Re: Check internet availability

Sorry but don't see anything in this project that checks for internet connectivity.  


Steven Kader at JaredCo
   Follow me on Twitter    |     Mipixi.com :  Web App for Photo Sharing
Developer
Posts: 194
Registered: ‎11-24-2012
My Device: Dev Alpha B, Bold 9700
My Carrier: NA

Re: Check internet availability

My mistake.  Check here:

 

https://github.com/blackberry/NDK-Samples

 

Project name NetworkStatus

Developer
Posts: 654
Registered: ‎02-03-2010
My Device: Z10 LE
My Carrier: Rogers

Re: Check internet availability

Thank you ...that was what I needed.


Steven Kader at JaredCo
   Follow me on Twitter    |     Mipixi.com :  Web App for Photo Sharing
Highlighted
Developer
Posts: 54
Registered: ‎05-23-2012
My Device: Developer
My Carrier: Developer

Re: Check internet availability

For info on how to integrate BPS event handling into Cascades (includes source code example):

 

http://developer.blackberry.com/cascades/documentation/dev/bps/

http://developer.blackberry.com/cascades/documentation/dev/bps/bps_tutorial.html

----
I know exactly where the problem *might* be.