Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

You can use on ionic 3 #116

Open
vijay471 opened this issue Sep 26, 2020 · 2 comments
Open

You can use on ionic 3 #116

vijay471 opened this issue Sep 26, 2020 · 2 comments

Comments

@vijay471
Copy link

vijay471 commented Sep 26, 2020

You can use on ionic 3

ionic cordova plugin add https://github.com/DmcSDK/cordova-plugin-mediaPicker.git --variable IOS_PHOTO_LIBRARY_USAGE_DESCRIPTION="your usage message"

let args = {
        "selectMode": 100, //101=picker image and video , 100=image , 102=video
        "maxSelectCount": 5,
        "maxSelectSize": 21000000 // 20mb
};

(window as any).MediaPicker.getMedias(args, (medias: any[]) => {
        console.log(medias);
}, (err: any) => {
        console.log(err)
});

Originally posted by @secretmoo35 in #105 (comment)

Not working😞

Error MediaPicker not function

@secretmoo35
Copy link

Platform you are using?

@dmlwls95
Copy link

dmlwls95 commented Jul 9, 2021

Hi, I solve this problem.
use like this

`
import ~~~
declare var MediaPicker;
@component({})

yourMethod(){
let args = {
        "selectMode": 100, //101=picker image and video , 100=image , 102=video
        "maxSelectCount": 5,
        "maxSelectSize": 21000000 // 20mb
};
MediaPicker.getMedias(args, (medias: any[]) => {
        console.log(medias);
}, (err: any) => {
        console.log(err)
});
}
`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants