• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
RE: TableView displaying a zillion empty rows
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: TableView displaying a zillion empty rows


  • Subject: RE: TableView displaying a zillion empty rows
  • From: Brian Hughes <email@hidden>
  • Date: Wed, 8 Jul 2009 01:36:25 -0400
  • Importance: Normal

So I changed my code to reflect Quincy Morris's recommendations.
-(int) numberOfRowsInTableView: (NSTableView *)aTableView {if (aTableView == gameScoresTableView) //This works as expected {
LNPlayer *currentPlayer = [playersArray objectAtIndex: currentIndex_]; NSMutableArray *tempGameRecordsArray = [NSMutableArray arrayWithArray: [currentPlayer gameRecordsArray]];return [tempGameRecordsArray count];}
else if (aTableView == playerManagementTableView) {NSLog (@"playersArray count = %d", [playersArray count]);  //[playersArray count] = 22return [playersArray count];}	else {NSLog (@"Invalid table view");return 0;}}
Since I only have two table views in my program the "Invalid table view" is never called.  The first table view gameScoresTableView works perfectly.  The playerManagementTableView does not.  I do not create the table views progammatically. I use IB. I do not use bindings. My delegates are set correctly and are the same for both table views.  I don't know enough about programming nor am I arrogant enough to think that there is something wrong with NSTableView.  I have always thought the error was in my code.  That is precisely why I asked for help.  I couldn't seem to figure out what to do next.  I have learned more about table views so I appreciate all the help.  However it still does not work.  I am going to try removing infrastructure and see if I can find the problem.  Any other suggestions would be welcome.  If I figure it out I will let you know.  Meanwhile I am going to shine that streetlight on the bottle of beer on my desk.  Maybe the solution is in there.
}


_________________________________________________________________
Lauren found her dream laptop. Find the PC that’s right for you.
http://www.microsoft.com/windows/choosepc/?ocid=ftp_val_wl_290_______________________________________________

Cocoa-dev mailing list (email@hidden)

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:

This email sent to email@hidden

  • Follow-Ups:
    • Re: TableView displaying a zillion empty rows
      • From: Andy Lee <email@hidden>
    • Re: TableView displaying a zillion empty rows
      • From: Quincey Morris <email@hidden>
References: 
 >Re: TableView displaying a zillion empty rows (From: Greg Guerin <email@hidden>)
 >Re: TableView displaying a zillion empty rows (From: Steve Christensen <email@hidden>)
 >RE: TableView displaying a zillion empty rows (From: Brian Hughes <email@hidden>)
 >Re: TableView displaying a zillion empty rows (From: Steve Christensen <email@hidden>)

  • Prev by Date: Cocoaheads Lake Forest (92630) meeting 7/8/2009 at 7 pm on dSym, the new symbol style for XCode
  • Next by Date: Re: TableView displaying a zillion empty rows
  • Previous by thread: Re: TableView displaying a zillion empty rows
  • Next by thread: Re: TableView displaying a zillion empty rows
  • Index(es):
    • Date
    • Thread