/// <summary> /// Valida si existe el expediente el linea de un cliente /// </summary> /// <param name="sCliente">Número de cliente</param> /// <returns></returns> public bool ExisteExpediente(string sCliente) { string FullPath = string.Format("{0}/{1}/{2}/", FTPCredentials.Path, ConnectionString.FolderConnection, sCliente); if (FTPServer.DirectoryExists(string.Format("{0}/{1}/", FTPCredentials.Path, ConnectionString.FolderConnection), FTPCredentials.User, FTPCredentials.Password, sCliente) && FTPServer.CheckIfFileExistsOnServer(FullPath, FTPCredentials.User, FTPCredentials.Password, "Log.txt") && FTPServer.Count(string.Format("{0}/{1}/", FTPCredentials.Path, ConnectionString.FolderConnection), FTPCredentials.User, FTPCredentials.Password, sCliente).Count > 13) { return(true); } else { return(false); } }
private void cargarCliente(string sCliente) { if (FTPServer.DirectoryExists(string.Format("{0}/{1}/", FTPCredentials.Path, ConnectionString.FolderConnection), FTPCredentials.User, FTPCredentials.Password, sCliente)) { //FlatMessageBox.Show("Expediente encontrado", "OK", string.Empty, FlatMessageBoxIcon.Information); //LLenar(); directories.Clear(); lvCarpetas.Items.Clear(); lvCarpetas.Visible = true; separatorControl1.Visible = true; //lnkAtras.Visible = true; //lnkAdelante.Visible = true; backgroundWorker1.RunWorkerAsync(); } else { FlatMessageBox.Show("No se encontro el expediente del cliente", "OK", string.Empty, FlatMessageBoxIcon.Warning); } }