Read More

Play audio file and save to document directory in iOS (Swift)

Play audio , save in document directory.

Some time we need to play a songs in application by using URL or pre save audio file. for this we need to follow some steps:

Steps are :

1: Avaudio player provides this facility;

Declare AVaudio player

Note: here “music ” is local store mp3 file .

2: by using URL:

for this we need to first download and play.

 

3: For access the downloaded file and again play.

 

4: you can also perform play and pause command .

 

 

 

 

 

 

 

 

 

 

 

 

 

. . .

Comments (7)

Add Your Comment

  • Bablu
    Nice one Bhai ji
    • kunal prasad
      thanks
    • kunal prasad
      thanks for your valuable comment , if you have any feed back or suggestion regarding blog content , you can share with us.
  • James
    Hello, Mr. kunal
    I need the same objective-c code.

    Thanks.

  • SWATI
    LIFE SAVER..THNX ALOT..
    • kunal prasad
      thanks for your valuable comment , if you have any feed back or suggestion regarding blog content , you can share with us.
  • css.php
    Hire Us!
    Brief us about your requirements and we'll get back to you.
    Woo! Hooy!
    We have just recieved your project brief and our expert will contact you shortly.
    Send Again
    Close