作者MAGICXX (逢甲阿法)
看板Python
標題[問題] 新增checkbox的問題
時間Thu May 30 16:46:42 2013
大家好
我現在正在嘗試在main window上面新增一個checkbox
我在我的code裡面 寫了這樣子的一個敘述句
他的object name我給他就叫做 checkbox
from ui_MainWindow import Ui_MainWindow
if Ui_MainWindow.checkbox.ischecked():
print "You select the item"
else:
print "Please select item"
可是他會一直給我
AttributeError: 'Ui_MainWindow' object has no attribute 'checkbox'
這個錯誤
請問 要怎麼修正這個錯誤呢?
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 140.112.63.202