Thread View: comp.sys.next.programmer
3 messages
3 total messages
Started by Hartmut Benz
Fri, 02 Oct 1992 16:36
The Appkit-Class *Form* does't take *setIntValue:at:* any more under 3.0
Author: Hartmut Benz
Date: Fri, 02 Oct 1992 16:36
Date: Fri, 02 Oct 1992 16:36
28 lines
1336 bytes
1336 bytes
Hi you gurus out there! I'm absolutely new to NeXT-programming so this question might be really stupid, but ... I have a small application running under 2.1 with a Form inside a Window like Field 1 [ ] Field 2 [ ] I have a connection 'fields' to this form and used to set values like this: [fileds setIntValue:someValue at:1]; and everything worked fine until THE UPRGRADE TO 3.0! After that (and the rebuilding of the application of course) nothing happens with this fields. Also the documentation on Form tells me not to use this method on it? Two Questions: 1. How do I do it? 2. Why has this been changed? Thanks in advance Hartmut _______________________________________ Hartmut Benz | benz@infko.uni-koblenz.de D-5400 Koblenz, Germany | (NeXTmail ok)
Re: The Appkit-Class *Form* does't take *setIntValue: at:* any more under 3.0
Author: Adrian Smith
Date: Fri, 02 Oct 1992 17:58
Date: Fri, 02 Oct 1992 17:58
53 lines
2200 bytes
2200 bytes
In article <1992Oct02.163647.20446@infko.uucp> benz@infko.uni-koblenz.de (Hartmut Benz) writes: > Hi you gurus out there! > > I'm absolutely new to NeXT-programming so this question might be really > stupid, but ... > > I have a small application running under 2.1 with a Form inside a Window like > > Field 1 [ ] > Field 2 [ ] > > I have a connection 'fields' to this form and used to set values like this: > > [fileds setIntValue:someValue at:1]; > > and everything worked fine until THE UPRGRADE TO 3.0! > After that (and the rebuilding of the application of course) nothing happens > with this fields. Also the documentation on Form tells me not to use this > method on it? > > Two Questions: > 1. How do I do it? > 2. Why has this been changed? > Well, in answer to your first question, it still works for me. I have a form called myForm. Create a controller that messages the form with a [myForm setIntValue:someValue at:0] Link a button to the controller. Compile. Click the button, and field 0 takes the intValue from someValue. Seems to work all right. As for the second question, if it still works, why not use it? All i can find in the documentation is a line in the setIntValue:at: method that says "Form does not override Control's setIntValue: method; your code should never use that method with a Form." -- Adrian Smith University of Alberta NeXT Campus Consultant adrian@niagara.ucs.ualberta.ca Audix: 5482
Re: The Appkit-Class *Form* does't take *setIntValue:at:* any more under 3.0
Author: Don Yacktman
Date: Fri, 02 Oct 1992 18:21
Date: Fri, 02 Oct 1992 18:21
41 lines
2147 bytes
2147 bytes
In article <1992Oct02.163647.20446@infko.uucp>, benz@infko.uni-koblenz.de (Hartmut Benz) writes:
>Hi you gurus out there!
I'm no guru, but I'll take a stab at this...
>I'm absolutely new to NeXT-programming so this question might be really
>stupid, but ...
>I have a small application running under 2.1 with a Form inside a Window like
> Field 1 [ ]
> Field 2 [ ]
>I have a connection 'fields' to this form and used to set values like this:
> [fileds setIntValue:someValue at:1];
>and everything worked fine until THE UPRGRADE TO 3.0!
>After that (and the rebuilding of the application of course) nothing happens
>with this fields. Also the documentation on Form tells me not to use this
>method on it?
>
>Two Questions:
>1. How do I do it?
I always use tags...
[[someMatrix cellWithTag:xxx] setIntValue:yyy];
^^^^^--I might not have the method name quite
right, since I haven't done this for
a while, but you get the idea.
The tags may be a bit slower, but it has one advantage that I really
like: the tag numbers can be #defines, and once I tag the cells,
they can be in any order, so I can shuffle around the fields nice
and easy in IB _without_ haveing to recompile. All I have to do is
change the tag in the .nib file. The tags always seemed a better way
to go, to me at least. It's flexible and doesn't hard code to location
in the matrix, which I feel is useful. (Of course, IB's default lays
out the tags predictably, you you can still code to position if
you don't muck with the tags.)
>2. Why has this been changed?
I don't know.
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads