Я пытаюсь открыть сохраненные видео с помощью кнопки в tkiner, но я получаю сообщение об ошибке -AttributeError: объект «Бицепс» имеет нет атрибута «ОС»
AttributeError: 'Biceps' object has no attribute 'os'
Это мой код
class Biceps(tk.Frame):
def __init__(self, parent, controller):
tk.Frame.__init__(self, parent)
label = tk.Label(self, text="Biceps!!!", font=LARGE_FONT)
label.pack(pady=10,padx=10)
button1 = tk.Button(self, text="Back to Home",
command=lambda: controller.show_frame(StartPage))
button1.pack()
button2 = tk.Button(self, text="Back to Menu",
command=lambda: controller.show_frame(Menu))
button2.pack()
rb1 = tk.Button(self, text = "Play", command=self.video).pack()
def video(self):
self.os.system("J:\Comp Project\Bicep.mp4")
Это ошибка:
Exception in Tkinter callback
Traceback (most recent call last):
File "C:\Program Files (x86)\Python35-32\lib\tkinter\__init__.py", line 1550, in __call__
return self.func(*args)
File "D:\Comp Project\Computer Science project2 test.py", line 253, in video
self.os.system("J:\Comp Project\Bicep.mp4")
AttributeError: 'Biceps' object has no attribute 'os'