procedure TForm1. Button1Click (Sender: TObject);
Var
Doc: IDocument;
Img: IImage;
Layout: ILayout;
The begin
Doc:=IDispatch (CreateOleObject (' MODI. Document) as the IDocument.
Doc. Create (' C: \ 1. BMP);//just put here the filename of the an image
Doc. OCR (miLANG_ENGLISH, true, true);
Img:=IDispatch (doc. Images [0]) as IImage;
Layout:=IDispatch (Img. Layout) as ILayout;
Memo1. The Clear;
Memo1. Lines. The Add (Layout. The Text);
MiDocView1. Document:=doc;
Doc. Close (false);
Img:=nil;
Layout:=nil;
end;
End.
Above is a use of MODI (Microsoft Office Document Imaging) for an example of OCR, consult everybody, how to manage the OCR screen for BMP images directly, rather than saved in hard disk and then call OCR recognition?
CodePudding user response:
See have no assgin luo, if not, since the interface is such, is not simple method directly estimates, to save the file, typically a yao is no big deal.CodePudding user response:
The