Exemplo n.º 1
0
        async void deletedAsync(FileSystemEventArgs e)
        {
            try
            {
                string selectFolder = "";

                for (int i = 0; i < Properties.Settings.Default.selectedFolders.Count; i++)
                {
                    if (e.FullPath.Contains(Properties.Settings.Default.selectedFolders[i]))
                    {
                        selectFolder = Properties.Settings.Default.selectedFolders[i];
                    }
                }

                string   name        = e.FullPath.Substring(selectFolder.Length + 1);
                string[] Directories = selectFolder.Split('\\');
                string   nameFolder  = Directories.Last();

                var obj = await client.deleteAsync(api, nameFolder + '/' + name);
            }
            catch (Exception ex) { }
        }