giandifra / simple_share

A Flutter plugin for share image, video or file
MIT License
18 stars 15 forks source link

iOS does not shows the apps like gmail #3

Open aravindhkumar23 opened 5 years ago

aravindhkumar23 commented 5 years ago

Hi, The plugin looks awesome and it saves me time.

I am facing a problem or maybe I am missing something with sharing a file with Gmail, It works in android but iOS does not show the list of apps in share extension.

is there something I need to do apart from installing the dependency in pubspec file?

The more option shows an empty list

file

giandifra commented 5 years ago

can you try example app of this repository? this result is strange.

giovapanasiti commented 5 years ago

I'm stuck in the same issue

giovapanasiti commented 5 years ago

@aravindhkumar23 can we see your code?

I ALMOST solved my problem.

void _sharePdf(String path) {
    final uri = Uri.file(path);
    SimpleShare.share(
        type: 'PDF',
        uri: path,
        title: "Share my file",
        msg: "My message");
  }

This is how I'm doing it now. The path is resolved and the file can be attached to an email. The only issue now is that the attached file doesn't have PDF extension even if the original file have it :(

aravindhkumar23 commented 5 years ago

@giovapanasiti I haven't used type as pdf, my file is filename.txt this is how I'm doing will it accept text as a type?

final uri = Uri.file(path);
    SimpleShare.share(
        subject: "Log file",
        uri: path,
        title: "Titel",
        msg: "message");
giovapanasiti commented 5 years ago

from what I've seen it has the behaviour you described when it doesn't find the file. Try to keep an eye on the log to see if any error message shows up.

giandifra commented 5 years ago

sorry, in this period i haven't iPhone device, i cant try