public ActionResult _GetFTPImagesList(string ClaimId, string Filter) { List <KeyValuePair <string, string> > lstFileNames = new List <KeyValuePair <string, string> >(); try { lstFileNames = _ftpService.GetALLFilesFromDB(ClaimId, Filter); lstFileNames = lstFileNames.Where(x => x.Key != null && !string.IsNullOrEmpty(x.Key) && x.Value != null && !string.IsNullOrEmpty(x.Value)).ToList(); } catch (Exception ex) { throw ex; } return(Json(new Result { Status = ResultStatus.Success, Message = "Success", Data = lstFileNames }, JsonRequestBehavior.AllowGet)); }