Re: buttonGroup and spinBox
Can we see the connect statement?
1 Attachment(s)
Re: buttonGroup and spinBox
Re: buttonGroup and spinBox
Are you sure the signal gets emitted? Do you get any warnings on the console during run time?
Re: buttonGroup and spinBox
nothing warning from console. Could the problem is the labels inside the button group (toghter the spinboxes)?
Re: buttonGroup and spinBox
Hmm... clicking labels or spinboxes won't trigger the signal. It only works for buttons, because only QButtons (and its subclasses) can be associated with a button group (as the name suggests).
Re: buttonGroup and spinBox
I dont' undertand: tried to do the same with another groupButton but doesn't work. It works if I connect each spinBoxes...
In myMainForm I coded (by hand) the same that I'd like now make from designer so
Code:
connect(buttonGroupE, SIGNAL(clicked(int)), this, SLOT (activeOption(int) ));
and this works!! What Am I wronging??
Re: buttonGroup and spinBox
Compile your app in debug mode and check whether you get any warnings in the console (remember about CONFIG+=console if you need it) about those connect statements during runtime.
Re: buttonGroup and spinBox
I'll trying this. But I inserted a button in side buttongroup together spinBox; if I click on pushButton the SLOT is called!!!WHile the spinboxes don't call the SLOT.....
Re: buttonGroup and spinBox
I already told you why:
Quote:
Originally Posted by wysota
Hmm... clicking labels or spinboxes won't trigger the signal. It only works for buttons, because only QButtons (and its subclasses) can be associated with a button group (as the name suggests).