def pwconfirm(self):
self.passwd = self.pswd.get()
if self.passwd is not None:
output = volttronFunc.agent_status(self.passwd)
try:
if output == '':
# pop up a window: remind the user to check his password.
tkMessageBox.showerror(title="Notification", message='Sorry, the password is incorrect, please try again.', parent=self.passwd_window)
self.passwd = None
self.passwd_window.state('withdrawn')
else:
self.passwd_window.state('withdrawn')
self.VOL_text.configure(state='normal')
self.VOL_text.delete('1.0', Tkinter.END)
self.VOL_text.insert('1.0', output)
self.VOL_text.configure(state='disabled')
self.passwd_window.withdraw()
except Exception as er:
print er
print('Error @ pwconfirm.')
评论列表
文章目录