Reputation: 1
Keep getting an error when I run my code
I have changed this many different times trying different things. I had this working a couple of days ago. I lost the program I was using and can't remember how it was put together.
class Gui(QtGui.QMainWindow, ui_hayfeeder.Ui_MainWindow):
def __init__(self):
super(self.__class__, self).__init__()
self.exiting = True
self.setupUi(self)
self.startup()
#self.pushButton_c_update.clicked.connect(self.update_clients)
self.pushbutton_bale1.clicked.connect(self.bale1)
def self.pushbutton_bale1 #getting error here
print "I am in here"
Print "I am in here"
Upvotes: 0
Views: 237
Reputation: 5452
It should be something like this:
class Gui(QtGui.QMainWindow, ui_hayfeeder.Ui_MainWindow):
def __init__(self):
super(self.__class__, self).__init__()
self.exiting = True
self.setupUi(self)
self.startup()
#self.pushButton_c_update.clicked.connect(self.update_clients)
self.pushbutton_bale1.clicked.connect(self.bale1)
def bale1(self):
print "I am in here"
Upvotes: 1