1

I would like to load html string with tableview Cell.

So first I tried with NSAttributedString, when I received an array from service I used for loop and added one more key with AttributedString and then I displayed it. But it is taking too much time to create AttributedString while records are more. Which is not acceptable in my app.

Now I am using UIWebView and loading that HTML string to cell, but it makes my tableview jumpy and stuck while user scroll normally.

I have to show and save all records while user first do login, so I can not go with paging while service call.

What other approaches can I try?

peter_the_oak
  • 3,529
  • 3
  • 23
  • 37
Kanjariya-IOS
  • 652
  • 1
  • 5
  • 17

1 Answers1

0

In your first attempt, you were setting the attributedText property of the tableview cell's label? And that was taking too long?

Would it work to lazily load results? For example, load 20 cells and when users scroll 75%-100% down the table load more? You can use this answer to help:

How to know when UITableView did scroll to bottom in iPhone

Community
  • 1
  • 1
terrafirma9
  • 362
  • 2
  • 15
  • terrafirmag #1 If i go with attributedText, than its talking much time in conversion from html text to attributedText. #2 If i go with webview and load html string, than it make my table cell jumpy while doing scroll. – Kanjariya-IOS Jun 01 '15 at 12:21