added cancel button to import dialog
created separate function to control adding stat values.