QList<QCheckBox *> widgets = findChildren<QCheckBox *>(); foreach(QCheckBox* checkbox, widgets) { connect(checkbox, SIGNAL(stateChanged(int)), this, SLOT(slotEnableSaveButton())); }