how to use Xam.plugin.FilePicker?

FraR1097FraR1097 Member ✭✭
edited September 11 in Xamarin.Forms

Good morning,
I'm trying to use Xam.plugin.FilePicker, on the android it opens the file finder , but it does nothing else,
on IOS does not even open the file finder, it should fill a variable with the file name and it doesn't, how do I solve it?

the code I use is this:

public async void SendFile()
    {
        try
        {
            FileData fileData = await CrossFilePicker.Current.PickFile();

            if (fileData == null)
                return; // user canceled file picking

            string fileName = fileData.FileName;

        }
        catch (Exception ex)
        {
            System.Console.WriteLine("Exception choosing file: " + ex.ToString());
        }

    }

Best Answer

Answers

Sign In or Register to comment.