MoveFile() public method

public MoveFile ( string sourcePath, string dectPath ) : List
sourcePath string
dectPath string
return List
Exemplo n.º 1
0
 //粘贴
 private void MenuItemPaste_Click(object sender, EventArgs e)
 {
     if (pasterTemp.Count > 0)
     {
         FSClient      client  = new FSClient();
         List <string> noPaste = client.MoveFile(pasterTemp.ToArray(), ConfigHelper.HdfsRoot + CurrentPath);
         if (noPaste.Count > 0)
         {
             try
             {
                 File.WriteAllText("c:/NoPaste.txt", string.Join("\r\n", pasterTemp.ToArray()));
             }
             catch (Exception ee)
             {
                 logger.Error("粘贴错误", ee);
             }
             MessageBox.Show("有" + pasterTemp.Count + "个文件或文件夹没有粘贴成功!请查看c:/NoPaste.txt详细!", "错误", MessageBoxButtons.OK, MessageBoxIcon.Information);
         }
         //清除剪切板
         pasterTemp.Clear();
         //重新加载
         LoadFileStatus(CurrentPath);
     }
 }
Exemplo n.º 2
0
 //粘贴
 private void MenuItemPaste_Click(object sender, EventArgs e)
 {
     if (pasterTemp.Count > 0)
     {
         FSClient client = new FSClient();
         List<string> noPaste = client.MoveFile(pasterTemp.ToArray(), ConfigHelper.HdfsRoot + CurrentPath);
         if (noPaste.Count > 0)
         {
             try
             {
                 File.WriteAllText("c:/NoPaste.txt", string.Join("\r\n", pasterTemp.ToArray()));
             }
             catch (Exception ee)
             {
                 logger.Error("粘贴错误", ee);
             }
             MessageBox.Show("有" + pasterTemp.Count + "个文件或文件夹没有粘贴成功!请查看c:/NoPaste.txt详细!", "错误", MessageBoxButtons.OK, MessageBoxIcon.Information);
         }
         //清除剪切板
         pasterTemp.Clear();
         //重新加载
         LoadFileStatus(CurrentPath);
     }
 }