That's how I started...
NSInteger testTag;
[ [ olPopups cellAtRow:0 column:0 ] setTag: counter];
testTag = [ [ olPopups cellAtRow:0 column:0 ] tag];

Thanks

--  Reinhard

Am 30.10.2010 um 00:18 schrieb Jonathon Kuo:

What's the point of doing this:
NSPopUpButtonCell *testCell = [ [ [ NSPopUpButtonCell alloc] init] autorelease];

It's just for testing


if you're doing this 2 lines later:
        testCell = [ olPopups selectedCell];


At this point, I would check for testCell being nil.

It is not, I can also see the tag changing after using setTag: in the debugger.

-Jon

On Oct 29, 2010, at 2:02 PM, Reinhard Segeler wrote:

Hi,
        Can't get the correct tag value in this way. What's wrong?

NSPopUpButtonCell *testCell = [ [ [ NSPopUpButtonCell alloc] init] autorelease];

        // olPopups is an Outlet to an NSMatrix
        [ olPopups selectCellAtRow:0 column:0 ];

        testCell = [ olPopups selectedCell];

        [ testCell setTag:1000];

        testTag = [ testCell tag];
        
results always in tag == 0, even though the tag value is shown correctly in the debugger.

Thanks

--  Reinhard

_______________________________________________

Cocoa-dev mailing list ([email protected])

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/newslists%40autonomy.caltech.edu

This email sent to [email protected]



_______________________________________________

Cocoa-dev mailing list ([email protected])

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to