Copy files showing progressbar [duplicate]

0

Good morning.

I have a small code where I copy files from one folder to another, but as some files take a while, I would like to show a progress bar, how can I do this with this code:

        string ArquivoOrigem = System.IO.Path.Combine(CaminhoOrigem, NomeArquivo);
        string ArquivoDestino = System.IO.Path.Combine(CaminhoDestino, NomeArquivo);

        File.Copy(Path.Combine(CaminhoOrigem, ArquivoOrigem), Path.Combine(CaminhoDestino, ArquivoDestino), true);

        System.IO.File.Copy(ArquivoOrigem, ArquivoDestino, true);
    
asked by anonymous 24.12.2015 / 13:00

1 answer

0

You can do this:

FileSystem.CopyFile(ArquivoOrigem, ArquivoDestino, UIOption.AllDialogs);

    
24.12.2015 / 13:08