private void btn_delfile_Click(object sender, EventArgs e) { #region 除文档 if (listBox1.SelectedItem == null) { MsgBox.ShowInfoMsg("请选择要删除的记录!"); } else if (MsgBox.ShowYesNoMsg("确定删除选中文档?") == DialogResult.Yes) { Ftp ftp = FtpControl.GetFtp("WorkOrder/" + model.WOCode); ftp.DeleteFileName((string)listBox1.SelectedItem); this.GetFTPFileList(model.WOCode); } #endregion }
private void btn_DelFile_Click(object sender, EventArgs e) { #region 除文档 if (listBoxAdv1.SelectedItem == null) { MsgBox.ShowInfoMsg("请选择要删除的记录!"); } else if (MsgBox.ShowYesNoMsg("确定删除选中文档?") == DialogResult.Yes) { Ftp ftp = new Ftp(invAddress, FTPConfig.UserName, FTPConfig.Password); ftp.DeleteFileName((string)listBoxAdv1.SelectedItem); this.GetFTPFileList(inv.InvCode); } #endregion }