Facing exception of "Exception has been thrown by the target of an invocation" while calling CreateEngine() method in Tesseract(4.1) dll. Please help me resolving this issue.

122 views
Skip to first unread message

Bhanu Prakash

unread,
Dec 15, 2022, 1:26:56 AM12/15/22
to tesseract-ocr
Hi , I am geting an exception of "Exception has been thrown by the target of an invocation" while calling CreateEngine() method in Tesseract(4.1) dll. Please help me resolving this issue.

This is stack trace of the Exception: "at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
at System.Reflection.RuntimeConstructorInfo.Invoke(BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at System.RuntimeType.CreateInstanceImpl(BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture,
Object[] activationAttributes, StackCrawlMark& stackMark)
at System.Activator.CreateInstance(Type type, BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture, Object[] activationAttributes)
at System.Activator.CreateInstance(Type type, Object[] args)
at InteropDotNet.InteropRuntimeImplementer.CreateInstanceT
at Tesseract.Interop.LeptonicaApi.Initialize()
at Tesseract.Interop.TessApi.Initialize()
at Tesseract.Interop.TessApi.get_Native()
at Tesseract.TesseractEngine..ctor(String datapath, String language, EngineMode engineMode, IEnumerable1 configFiles, IDictionary2 initialOptions, Boolean setOnlyNonDebugVariables)
at Tesseract.TesseractEngine..ctor(String datapath, String language, EngineMode engineMode)
at AR_Agents.HOCR.CreateEngine(String lang, EngineMode mode)
Reply all
Reply to author
Forward
0 new messages