I have the code below,after retrieving the file i want to convert it to json.
Any help is appreciated.
- public string DownloadDocument(string documentname, string documentlocation)
- {
- string obj = string.Empty;
- DirectoryInfo d = new DirectoryInfo(documentlocation);
- FileInfo[] Files = d.GetFiles();
- foreach (FileInfo file in Files)
- {
- if (file.Name.Contains(documentname))
- {
-
-
- }
- }
- return obj;
- }