How to update documents inside Training batch via API in FlexiCapture 12

You may need to update documents inside your FlexiCapture training batches to the latest version of  Document Definition. The simplest way is via Project Setup station GUI (right-click on batch > Update to the latest version). Below is the example of updating via FlexiCapture Web API

Step-by-step guide

The idea is that update requires documents to be re-recognized using the current version of Document Definition.

The original project with API usage example: https://help.abbyy.com/en-us/flexicapture/12/developer/unattendedexample

Project name - Program.cs:105

Adjust the project with the following code

if (project.Name != "eui") continue;
private static void Update(FlexiCapture.
        FlexiCaptureWebServiceSoapClient service, int userId, int sessionId, int projectId, string filename)
        {
            //findU
            var uid = service.FindUser("ABBYYUKR\\NShevchenko");
            FlexiCapture.User user;
            service.GetUser(uid, out user);

            var listst = service.GetAvailableTasks(sessionId, projectId, 500, false);
            service.GetTaskInfo(0);

            var batches = service.GetBatches(projectId,sessionId,false);
            for (int i=0;i<batches.Count;i++) {
                FlexiCapture.Batch b = batches[i];
                service.ProcessBatch(sessionId, b.Id);
            }


If the server is not local, then you should configure the reference.

Related articles

More information about API usage: https://help.abbyy.com/en-us/flexicapture/12/developer/api

Was this article helpful?

0 out of 0 found this helpful

Have more questions? Submit a request

Comments

0 comments

Please sign in to leave a comment.

Recently viewed