def set_directory(self):
    try:
        self.working_dir = filedialog.askdirectory(initialdir=self.working_dir)
        wbt.set_working_dir(self.working_dir)
    except:
        messagebox.showinfo('Warning', 'Could not set the working directory.')
def set_directory(self):
    try:
        self.working_dir = filedialog.askdirectory(initialdir=self.working_dir)
        wbt.set_working_dir(self.working_dir)
    except:
        messagebox.showinfo('Warning', 'Could not set the working directory.')