objective c - How do I load a CSV in IOS after saving it locally -
i have csv file i'm downloading s3 account , show in ios app using quicklook framework. the error i'm getting in console. says qlpreviewcontroller's datasource shouldn't nil @ point. this appears after line of code runs // set data source [previewer setdatasource:self]; here's code downloading file, saving , loading quicklook -(void)showdocument { nsstring *stringurl = @"http://jornada.s3.amazonaws.com/dust.csv"; nsurl *url = [nsurl urlwithstring:stringurl]; nsdata *urldata = [nsdata datawithcontentsofurl:url options:nsdatareadinguncached error:nil]; if ( urldata ) { nsarray *paths = nssearchpathfordirectoriesindomains(nsdocumentdirectory, nsuserdomainmask, yes); nsstring *documentsdirectory = [paths objectatindex:0]; nsstring *filepath = [nsstring stringwithformat:@"%@/%@", documentsdirectory,@"tempfile.csv"]; //[urldata writetofile:filepath atomically:yes...