ScanFix Xpress v9.0 for .NET - Updated
Use a Series of Cleanup Operations
User Guide > How To > Use a Series of Cleanup Operations

The Enhancements object in ScanFix® Xpress can be used to setup, execute, save, and load a series of ScanFix Xpress cleanup operations. This mechanism can be used to develop applications that perform a fixed series of operations on one or more images. The Enhancements sample application demonstrates using the Enhancements object API.

Set Up Series of Operations

The Enhancements object holds an ordered list of “option” objects. Each option contains the operation and properties for a single ScanFix Xpress cleanup operation. Options will be performed in the order they are stored in the options list.

With most operations, the option object is the same object that holds properties for a single operation. For example, a DeskewOptions object is used for Deskew cleanup operation properties.

For methods that do not have an options object there are special objects for use with the Enhancements options list. For example, to add a Flip operation you would create a FlipOptions object (which has no properties) and add it to the Enhancements list.

In Summary:

Execute Series of Operations

The operations in an Enhancements options list can be applied to the image held by a ScanFix Xpress object calling the ExecuteEnhancements method. This will execute, in sequence, each option in the list. 

The results from each cleanup operation will be a single results object. After successful execution, the Enhancements object will contain a list of results objects, where each results object contains results for the corresponding options list object.

If there is an error or exception during execution of any operation, then the results list will be incomplete or empty. In this case, the results list will contain results objects for each operation before the failing operation. The ScanFixException object will contain Number and Message properties for the operation that failed.

In Summary:

  1. Create and configure Enhancements object (see "Set Up Series of Operations" above).
  2. Create ScanFix Xpress object.
  3. Load image into ScanFix Xpress object.
  4. Call ScanFixObject’s ExecuteEnhancements() method and pass the configured Enhancements object.
  5. Compare Enhancements object results list size with options list size to see if all operations were completed successfully.
  6. Transfer processed image from ScanFix Xpress object.
Steps 3-6 can be repeated to process a series of images using a single Enhancements object.
Is this page helpful?
Yes No
Thanks for your feedback.