Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8455377
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T12:16:20+00:00 2026-06-10T12:16:20+00:00

I am making a bookmarks page for my web browser and the problem is

  • 0

I am making a bookmarks page for my web browser and the problem is that everytime I add a new object, I have to set the properties since I created a custom cell (I must set the text of two labels) and so I need a way to only edit the newly added object…I’m familiar with indexes but not able to come up with any solutions to this problem…For example when I bookmark the first page its fine, but once I bookmark 2 pages the 2 cells are the exact same…Any Ideas?

Heres My Code:

// Customize the appearance of table view cells.
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {

static NSString *CellIdentifier = @"CustomCell";

CustomCell *cell = (CustomCell*)
[tableView dequeueReusableCellWithIdentifier:CellIdentifier];
if (cell == nil) {
    NSArray *nib = [[NSBundle mainBundle] loadNibNamed:@"CustomCell" owner:nil options:nil];
    cell = (CustomCell *) [nib objectAtIndex:0];

}

// Set up the cell...

     NSString *theTitle=[webView stringByEvaluatingJavaScriptFromString:@"document.title"];
NSString *currentURL = webView.request.URL.absoluteString;
      cell.websiteTitle.text = theTitle;
cell.websiteURL.text = currentURL;
universalURL = currentURL;




return cell;
}

When setting up the cell I need to point to the newest cell!

Thank You In Advance!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T12:16:22+00:00Added an answer on June 10, 2026 at 12:16 pm

    Your approach cannot work. You cannot use the cells as the store for the titles and URLs, because cells are reused (and because it is bad design). A table view allocates only cells for the visible rows and reuses a cell for a different row when you scroll the table view.

    Instead you should store the titles and URLs in a separated data source, for example an NSMutableArray *bookmarks where each item in the array is a NSDictionary with “title” and “URL” keys.

    To add a bookmark to your table, you just append a new entry to the array and call reloadData on the table view.

    The tableView:cellForRowAtIndexPath: method can then use the bookmarks array with the row number indexPath.row to fill all elements of the cell.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Making a word document of our network set-up. We have about 7 servers and
Making websites that appear correctly in IE is a big problem. Is there any
Making a flash page that can cycle through these three images on mouseclick. For
I am having a strange problem while making app requests. I understand that when
I am making an html/javascript browser homepage, that could be downloaded to any computer
Making a new site but something is happening to it in IE8. The social
Making a new site but something is happening to it in IE. I've purchased
Making an adobe flex ui in which data that is calculated must use proprietary
Making my first steps in RIA Services (VS2010Beta2) and i encountered this problem: created
Making UML sequence diagram in VS 2010RC I've observed that there is no activation

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.