Hello,
All of the examples you provided showing how to read files from local file storage and save them to local file storage.
How can I achieve that if the user attaches the scanned pdf file, OCR that file (make searchable pdf) and return the result (searchable pdf) back to the user?
This is kind of the idea
[HttpPost]
public IActionResult SearchablePdf(IFormFile file)
{
var fileStream = file.OpenReadStream();
var memoryStream = new MemoryStream();
fileStream.CopyTo(memoryStream);
var ocr = new AsposeOcr();
var pdfResult = ocr.RecognizePdf() // is this method doesnt get any kind of stream?
var imageResult = ocr.RecognizeImage(memoryStream, new RecognitionSettings() { Language = Language.None});
imageResult.Save(“test.pdf”, SaveFormat.Pdf); //in here how can i return searchable pdf back to user instead of saving to local
}