FROM : Fritz Anderson
DATE : Sat Nov 23 21:31:15 2002
Do you mean you want to select one radio button in an NSMatrix of them?
If the buttons are arranged vertically, do this:
int selection;
[radioMatrix selectCellAtRow: selection column: 0];
To get the selected button do this:
selection = [radioMatrix selectedRow];
The NSMatrix ensures the proper radio-button behavior of only one
selection at all times.
The tag value of the cells is there for your reference only, and does
not affect the appearance or behavior of the cells.
-- F
On Friday, November 22, 2002, at 07:10 AM, Uwe Schlosser wrote:
> I would like to set a RadioButton (5 button in a row) programatically.
>
> I tried a way similar to a IBAction methode
>
> -(void)boxAuswahlIntern:(int)value
> {
> id theCell = [myRadioButton selectedCell]; //myRadioButton is
> IBOutlet and right connected IB
> [theCell setTag:value];
> }
>
> but this does not work!
>
--
Fritz Anderson - Consulting Programmer - Chicago, IL
Mail: <<email_removed>>
Risumi: <http://resume.manoverboard.org>
_______________________________________________
cocoa-dev mailing list | <email_removed>
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
DATE : Sat Nov 23 21:31:15 2002
Do you mean you want to select one radio button in an NSMatrix of them?
If the buttons are arranged vertically, do this:
int selection;
[radioMatrix selectCellAtRow: selection column: 0];
To get the selected button do this:
selection = [radioMatrix selectedRow];
The NSMatrix ensures the proper radio-button behavior of only one
selection at all times.
The tag value of the cells is there for your reference only, and does
not affect the appearance or behavior of the cells.
-- F
On Friday, November 22, 2002, at 07:10 AM, Uwe Schlosser wrote:
> I would like to set a RadioButton (5 button in a row) programatically.
>
> I tried a way similar to a IBAction methode
>
> -(void)boxAuswahlIntern:(int)value
> {
> id theCell = [myRadioButton selectedCell]; //myRadioButton is
> IBOutlet and right connected IB
> [theCell setTag:value];
> }
>
> but this does not work!
>
--
Fritz Anderson - Consulting Programmer - Chicago, IL
Mail: <<email_removed>>
Risumi: <http://resume.manoverboard.org>
_______________________________________________
cocoa-dev mailing list | <email_removed>
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
| Related mails | Author | Date |
|---|---|---|
| Uwe Schlosser | Nov 22, 14:10 | |
| Fritz Anderson | Nov 23, 21:31 |






Cocoa mail archive

