Search code examples
iphoneobjective-cnsurlconnection

NSURLConnection Error


What is "Error Domain=NSURLErrorDomain Code=-1020 UserInfo=0x1694a0 "Operation could not be completed. (NSURLErrorDomain error -1020.)"" due to ??


Solution

  • The error codes you get from NSURLConnection are in NSURLError.h and CFNetworkErrors.h, as well as this Apple documentation. It looks like -1020 is kCFURLErrorDataNotAllowed, which says:

    "The connection failed because data use is currently not allowed on the device."