# Use image picker to save photos to 2 different image view (swift3)

**URL:** <https://forums.kodeco.com/t/use-image-picker-to-save-photos-to-2-different-image-view-swift3/26873>\
**Category:** Swift\
**Created:** [March 4, 2017, 3:46am UTC](https://forums.kodeco.com/t/use-image-picker-to-save-photos-to-2-different-image-view-swift3/26873 "2017-03-04T03:46:41Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![zalubski](https://assets.chunter.kodeco.com/user_avatar/forums.kodeco.com/zalubski/32/81494_2.png) [@zalubski](https://forums.kodeco.com/u/zalubski)\
**Post date:** [March 4, 2017, 3:46am UTC](https://forums.kodeco.com/t/use-image-picker-to-save-photos-to-2-different-image-view-swift3/26873/1 "2017-03-04T03:46:41Z")

</div>

I want the user to take 2 different photos using 2 different imageviews and 2 different buttons (a left and right side). I know how to do this with using imagepicker Delegate but not with 2 different imageviews. Both imageviews will have different photos and use a different button to take the photo. Basically the left and right sides have nothing to do with each other.

 ![](https://raywenderlich-com-v3-forums.s3.amazonaws.com/original/3X/2/8/2877436fe661771666a11bc9b5d643155158afb2.png)

```
       import UIKit

        class _vc: UIViewController {

       @IBOutlet var leftImage: UIImageView!
      @IBOutlet var rightImage: UIImageView!

      override func viewDidLoad() {
       super.viewDidLoad()

       // Do any additional setup after loading the view.
      }

     @IBAction func takePhotoLeft(_ sender: Any) {
     }
     @IBAction func takePhotoRgith(_ sender: Any) {
    }}

```

---

<div class="post-metadata">

**Author:** ![aeberbach](https://assets.chunter.kodeco.com/user_avatar/forums.kodeco.com/aeberbach/32/81494_2.png) [@aeberbach](https://forums.kodeco.com/u/aeberbach)\
**Post date:** [March 5, 2017, 10:42pm UTC](https://forums.kodeco.com/t/use-image-picker-to-save-photos-to-2-different-image-view-swift3/26873/2 "2017-03-05T22:42:17Z")

</div>

What’s the main issue you are having trouble with? I think you will still use `UIImagePicker` and `imagePickerController(_:didFinishPickingMediaWithInfo:)` - the only thing you might need to do differently is record which is the active view you are trying to save an image for so that you can choose which view to populate once an image is picked.
