-2

I would like to choose a video from the library(which I have completed) NOW, I want to take that video and display it in a view controller. What do I do? I have looked everywhere and have found nothing.

  Here is my code for trying to get the file name of a selected video from the library, which I am trying to display in a webview. It does not work.

videoURL = info[UIImagePickerControllerReferenceURL] as! NSURL?

let fileURL = NSURL(fileURLWithPath: " (videoURL)")

videoView.loadHTMLString( " ", baseURL : nil)

Any help is much appreciated. Thanks!

  • 1
    Possible duplicate of [How to play a local video with Swift?](http://stackoverflow.com/questions/25348877/how-to-play-a-local-video-with-swift) – pableiros Nov 30 '16 at 20:21

1 Answers1

-1

You'll need to implement the delegate methods.. Check this out:

How to select any Video or Movie file from UIImagePickerController

Community
  • 1
  • 1
JDM
  • 883
  • 1
  • 8
  • 20