Thank you for reading this.

I want to set a table widget header based on its cell contents.

The following sets all of the headers;

self.tableWidget.setHorizontalHeaderLabels(["One", "Two", "Etc"])

However, self.setHorizontalHeaderItem ( 1, ["test"]) and self.setHorizontalHeaderItem ( 1, "test") fail with the following error;

"'MainWindow' object has no attribute 'setHorizontalHeaderItem'"

setHorizontalHeaderItem() exists in the documentation so I must be using it incorrectly. I've played with this for quite some time and searched the Internet for an answer. Can anyone offer a suggestion?

--
Regards,
Phil
_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor

Reply via email to