TN IB002 Create Batch Scheduler in InTouch Using InBatch ActiveX Objects
Description
This article from InSource shows how to create a custom interface in InTouch that will create and schedule InBatch batches manually by the operator.
- Author: Chris Sselph
- Published: 10/18/2019
- Applies to: Versions of InBatch and InTouch > 2012
Details
Assumptions:
1. The InBatch Configuration is complete
2. Batch Runtime Client is installed on the development PC
3. Batch Runtime Client has been configured via Configurator on the development PC
Steps Overview
1. Create a new InTouch application or use existing
2. Install Batch ActiveX objects (note Batch .Net objects are available for use in ArchestrA Graphics)
3. Create window for BatchGUICfg object (hidden)
4. Create Batch Scheduling Window and Batch Recipe Select Window (popup)
5. Insert BatchGUIConfig object and configure
6. Insert Batch Lists, Fields and Buttons ActiveX objects and configure
7. Run to Test
The way it works
The BatchGUIConfig object establishes communication between InTouch and the Batch server.
The batch objects (Lists, Buttons and Fields) communicate to the Batch server via the BatchGUIConfig
The batch objects (Lists, Buttons and Fields) communicate to each other automatically.
Steps
1. Create a new InTouch application or use existing
Assuming this has been done and you are editing this application in WindowMaker
2. Install Batch ActiveX objects (note Batch .Net objects are available for use in ArchestrA Graphics)
Use menu Special>Configure>Wizard/ActiveX
Find InBatch Objects, select and click Install
3 & 4 - Create 3 Windows
5. Insert BatchGUIConfig object and configure
on window to be hidden, insert BatchGUIConfig ActiveX
Configure as follows:
Hosts should be your Primary and Redundant InBatch server node names
Next we will be adding AxtiveX objects for Batch Lists, Fields and Buttons, all from the same place as seen here:
You will be creating an interface that looks like this in general:
Here is how you configure the objects by simply pointing to the function you want them to be:
A List representing the Batch Schedule
A field representing the Campaign portion of the batch identifier
A button to execute an action like schedule the batch
Configure all objects on the window as such
The Recipe... and Train ... buttons are a little different. We do not want the list of Recipes and Trains to choose from always on this window. We want a popup window to appear so the user can select the Recipe and Train.
The Recipe and Train buttons are configured as example here:
Both buttons are configured to call the popup window with an ActiveX script as seen here:
The recipe select window has the recipe and train lists and "apply" buttons.
7. Run to Test
Before Testing, use the built in batch scheduler on the batch server to schedule some batches for testing.
Run your application in WindowViewer
The Schedule list should reflect the same batches you just scheduled, if not, check the BatchGuiConfig is on an open window and configured properly.
If the schedule looks good, type in the batch parameters (Campaign, Lot...Recipe, Train etc) and click schedule, the schedule list should reflect that new batch.
Note you will need to add the "Schedule Control" buttons seen on the right for complete control.
END