login about faq

I am using chilkat ios library to fetch email from mail server, i am using following code to fetch emails .... CkoMessageSet messageSet; messageSet = [imap Search: @"ALL" bUid: fetchUids]; CkoEmailBundle bundle; bundle = [imap FetchBundle: messageSet];

this takes lots of time to fetch emails if mail box size is to large. please provide solution for this.

Thanks satish

asked Jul 16 '12 at 01:22

satish's gravatar image


Yes, that is correct. Downloading 1000 emails would generally take about 10 times longer than downloading 100 emails...


answered Jul 16 '12 at 08:01

chilkat's gravatar image

chilkat ♦♦

Yes,is there any solution for it to update performance?

waiting for response. Thanks

(Jul 16 '12 at 10:26) satish

Do you NOT understand why downloading 1000 emails would take 10 times longer than downloading 100 emails? Really?

(Jul 16 '12 at 13:14) chilkat ♦♦

yes I understood, I need to fetch 2000 and above mails at a time and it takes me very long time to fetch those mails. So to reduce the time limit give me some solution which will not take more time in ios.

(Jul 17 '12 at 07:40) satish

There are a number of solutions:

  1. Instead of calling FetchBundle, iterate over the messages in the message set and fetch them one at a time.
  2. Put your email fetching code in a background thread. I cannot provide general programming instruction for how to write multi-threaded programs. In general, when using background threads, your program should be thread-safe meaning that any shared object instances or other variables should not be simultaneously modified/accessed. You'll need to synchronize access to these things. (Chilkat objects are automatically thread-safe.) If a long-running task is in a background thread, then your foreground thread is free to handle the user-interface.
  3. Use event callbacks, such as periodic AbortCheck events, allowing you to manage user-interface updates. Again, I cannot provide general IOS user-interface programming advice. I can only provide information about the event callback behavior itself. (see http://www.chilkatforum.com/questions/292/event-callbacks-in-ios-objective-c )

answered Jul 17 '12 at 10:41

chilkat's gravatar image

chilkat ♦♦

edited Jul 17 '12 at 10:41

Thanks for response.

I have already used first option.

I will use threading to perform fetching large no of email.

Once again Thanks for solution.

(Jul 18 '12 at 02:31) satish
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or __italic__
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported



Asked: Jul 16 '12 at 01:22

Seen: 1,037 times

Last updated: Jul 18 '12 at 02:31

powered by OSQA