Added progress dialog, + check for internet connection