Skip to content

Erro DeleteAsync #244

Description

@CrisRogoy

I'm trying to delete a file or folder and it's giving me the following error
"System.ArgumentNullException: 'Value cannot be null. Arg_ParamName_Name'"

But this is OK, it's just a test and the variable "oo" IS NOT NULL but it gives the same error.

I'm using version 1.10.4

Here is just a test

        IEnumerable<INode> nodes2 = await MClient.GetNodesFromLinkAsync(new Uri("https://mega.nz/folder/CgwjRapBeyNl10emvGN9H-9tg"));

        ListStatus.Items.Clear();

        INode oo = null;

        foreach (var item in nodes2)
        {
            if (item.Type == NodeType.Directory)
            {
                oo = item;
                break;
            }
        }

        Progress<double> PProgresso = null;
        PProgresso = new Progress<double>(p => ProgressBar.Value = Convert.ToInt32(p));
        PProgresso.ProgressChanged += PProgresso_ProgressChanged;

        await MClient.DownloadFileAsync(oo, $"C:\\TEMP\\{oo.Name}", PProgresso);

        await MClient.DeleteAsync(oo);

        await MClient.LogoutAsync();

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions