objective c - Replace %20 with space character while saving file iOS -


i recording audio file , saving document directory. given name contain space character. when save document directory, space characters changed %20. know how save that audio file name contain space character.

    nsstring *mydbnew = [documentsdirectory stringbyappendingpathcomponent:recordingaudioname ];     nsurl *recordedtmpfile = [nsurl fileurlwithpath:mydbnew]; 

edited - audio recording , save local directory.
recorder = [[ avaudiorecorder alloc] initwithurl:recordedtmpfile settings:recordsetting error:&error];

you're using nsurl , spaces invalid characters in url. that's why it's converted %20.


Comments

Popular posts from this blog

html - Sizing a high-res image (~8MB) to display entirely in a small div (circular, diameter 100px) -

java - IntelliJ - No such instance method -

identifier - Is it possible for an html5 document to have two ids? -