I am using IronOCR OCR Library to read text from a particular area within a PNG image which goes fine. However, I need to do the same with a directory/folder and save it to a directory/folder.
Here's the code that I am currently using
public void workOCR()
{
var ocr = new AutoOcr();
var Area = new Rectangle()
{
X = 1367,
Y = 420,
Height = 57,
Width = 411
};
var result = ocr.Read(@"C:\Users\fasihullahkhan\Desktop\pdftopng\page3.png", Area);
label1.Text = result.Text;
}
What I want to do is specify a directory like this:
ocr.Read(@"C:\Users\fasihullahkhan\Desktop\pdftopng\", Area);
From within a loop, but I don't know how. Please help.