dialog box now works