Beispiel #1
0
        async void renamedAsync(RenamedEventArgs 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 folder = await client.moveAsync(api, nameFolder + '/' + e.OldFullPath.Substring(selectFolder.Length + 1), nameFolder + '/' + name);
            }
            catch (Exception ex) { }
        }