I want to check if the connection to a host url is successful or not, without using internet. My Android application will not use internet. The connection to host url is right now done with the help of VPN.
But in the future, the connection will get changed from VPN to something else, may be APN. And, users will be able to connect to host url with that connection. So, I should be able to check whether user is able to connect to the host url or not. if not, then I will have to stop user from using the application.
Let me know if it is possible to check the connection status without internet connection. And if yes, please give me the solution. I have tried different ways but all of them give me error when internet is not available.