To Execute this Example

LANSA

To Execute this Example
LANSA User Agent - Interactive File Conversion and UploadThe Things that Make Up this Example

Ensure that JSM is working and started and in particular that the DC@W29 entry for this example has been added.

Example 233 requires this row in table DC@W29 on the remote host system:
Column NameValueComments
W29SRV – Service NameSET_233_CSV 
W29LHO – Web server ip addresseg: 123.123.123.123:80Enter iSeries IP address in Host:Port format
W29MOD – Process NameSET_233 
W29FMT – Function NameSET233S 
W29P#I – Partition <ppp> Specify the partition in which the SET collection was installed (<ppp> is typically DEM)
W29PLN – Language Blank or< LLL> If the partition is monolingual set this column to blanks. Otherwise set it to the language your are using (<LLL> is typically ENG, FRA, JPN).
W29PGM – ProgramSet to blanksDo not specify this value

To use the SVHEAD keyword, a configuration entry needs to be added to the HTTPService.Properties file, typically located in your iSeries IFS system in the /jsm/instance/properties directory. Edit this file and add two lines:
# for SET_233
sv.head.SET233S=EMPNO,SALARY

Ensure that LANSA User Agent is installed correctly on your PC.

Put the contents of zip file SET_JSM_UserAgent.zip into the LANSA User Agent directory on your PC:
  • If you imported the windows SET import material, SET_JSM_UserAgent.zip can be found in the partition execute directory.
  • If you imported the iSeries SET import material, SET_JSM_UserAgent.zip can be found with the web images, or in the SETIMGCUR save file.
Edit your host configuration file SET_233_CSV.lih using notepad. You will need to change:
  • The host – this is the ip address of your web server
  • The host uri for file sources (if “/cgi-bin/jsmdirect” is not the location of jsm direct in your iSeries web server configuration. )
Start the LANSA User Agent. Select the host SET_233_CSV.lih. Select the source SET_233_Employee_New_Salary.xls. Take the option to Send. If everything is configured correctly, you should see a pop up window with the message “Send Action has completed”, and you should be able to see the response from server function SET233S under the response tab.

When you’re confident that its working, a variation you can try is:
  • Select SET_233_Employee_New_Salary.csv as the source (input data). This is handled just the same as excel spreadsheet source.
What to do if a JSM based example does not work:

If you are running the LANSA User Agent using the HTTPClient service:
  • Check the response tab sheet on the LANSA User Agent
  • Locate the HTTP Server instance job used by your job and read the messages in its job log.
  • Trace files (see section on obtaining trace files)