check if connected, otherwise show dialog box for