views:

193

answers:

1

Hi guys,

In my app I give the user the ability to download files from a server. For that I use NSURLConnection. I would like to give the user the ability to pause and resume the download by tapping a button. I couldn't find any way to do this besides calling the cancel method and then creating a new NSURLConnection. So is there an elegant way to pause NSURLConnection?

Thanks

+3  A: 

That's the only method I'm aware of. If your server supports the "Range:" header, you can then create a new connection and have it pick up where the other one left off.

Ben Gottlieb