This sample shows how to create an Excel macro to enter data into an InfoConnect demo terminal session from an Excel spreadsheet.
If you prefer to run macros in pre-configured sessions instead of creating your own sessions, you can download the VBA Sample Sessions and open the enter-data-from-an-excel-spreadsheet.xlsm (IBM) file. The download package contains everything you need to run the macros in this file. See Download the VBA Sample Sessions.
This sample applies only to IBM terminals
This macro creates a new InfoConnect session as explained in Create a Session From a Microsoft Excel Macro. Then it navigates to the screen that has the data form.
It assigns the values from the current row in the Excel spreadsheet to local variables and puts these values into the appropriate fields on the first screen, using the PutText2 method. After putting the values into the form, it enters the data in the program using the SendControlKey method.