Access shared IFS folder on another machine

Access shared IFS folder on another machine

This article can help you, if you are trying to access a shared folder e.g. on an IBM i machine from InterFormNG2. This includes situations like these:
  1. InterFormNG2 is running on Windows, but need to access a shared folder in the IFS on an IBM i - either for input files or as a folder to place generated files e.g. PDF files.
  2. InterFormNG2 is running on an IBM i (or any other platform actually) and need to access a shared folder on another IBM i or even a shared folder on a Windows machine - either for input file or as a folder to place generated files e.g. PDF files.
The best solution is to use one of the many Windows share options and below a few examples are listed.

The alternatives are:
  1. You can consider to use FTP: Both To FTP and Read from FTP, but very often the FTP service is not allowed to run.
  2. On Windows you can consider to map a network drive to a drive letter, but that will only work if the mapped network drive was made by the same user as the user under which InterFormNG2 is running.
  3. On the IBM i platform you might be able to access shared folders on other server via the QNTC folder, but that require that the job (the InterFormNG2 service) runs under a user profile (and password) which has access to the shared folder on the other server.
Getting started: Save to a shared folder
Even though you might want to monitor a shared folder for new input files it is still a good idea to first try to create a new file on the shared folder to ensure, that the settings for the connection are correct.
You can e.g. do that by simply monitoring a local input folder and then simply save the input file on the shared folder.

In this example InterFormNG2 runs on Windows and we would like to save the input file to the IFS on an IBM i. On the IBM i there is a folder called, APFF3812Home. This folder is already shared and the share name is APF3812Home. 

The simple setup to do this is the workflow below:


The input element looks like this:


So it simply monitors the folder inbox_saveInIFS inside the InterFormNG2_Home folder, which in this case is:
C:\ProgramData\InterFormNG2, so the full path to the monitored input folder is:
C:\ProgramData\InterFormNG2\inbox_saveInIFS

The next workflow component is To dynamic Windows Share, which has this setup:


The parameters are:

Server address
This is the server name or IP-address of the IBM i, onto which we want to save the file.

Share
This is the name of the share, which has been defined. With the value, APF3812Home we refer to the share name, APF3812Home

Path and file name
This could have been setup with XPath to make it a dynamic path and/or file name. Here we use the path: /Work/inputfile.xml, which means that the full path to the saved file will be /APF3812Home/Work/inputfile.xml

Username
Here the user id for the connection is selected. This is a user id, that exists on the other machine - with the stated IP-address.

Password
The password on the other machine for the user Id stated above.

Domain
If the other server is accessed via a domain, then you need to state the domain here. If a domain is not used, then you should leave this parameter blank.

If the workflow works and is able to save the file, then you have verified the connection and you can move on.
Create a PDF and save it to a shared folder
In this example we want to generate a PDF file and save it to a shared folder.

In order to do that we first need to create a PDF and store it in the payload of the workflow. We can do that with the workflow component, Create PDF document and the upload the PDF file to the shared folder with e.g. the workflow component, To dynamic Windows Share as in the previous section. 

Instead of the To dynamic Windows share you can also first define a Windows Share connection and then refer to the connection name in the workflow component, To Windows Share.
Monitor a shared folder e.g. in the IFS on another machine
If we have already been able to create a test file on a shared folder on another machine, then we know that the configuration of the connection is fine.

Then we can simply create a new workflow with the input type: From Windows share in order to monitor a folder on a remote machine (still via a shared folder). 
 




    • Related Articles

    • Can InterForm dynamically pick up images from the IFS or even from another server?

      Yes, you can refer to any reachable image by stating a dynamic URL or path for the image. The path or URL be dynamic and e.g. include dynamic data, that is retrieved from the input file. It is also very easy to add a URL for the image, to make it ...
    • InterFormNG2 machine information missing in Windows

      In the InterFormNG2 license screen the machine information might be missing if you are running InterFormNG2 on the Windows platform. If the machine information is missing, then you will see a license screen like below: In the bottom both the System ...
    • InterForm400 Analysis and Conversion Report Aid (PTF)

      The InterForm400 Analysis and Conversion Report Aid (PTF) is an IF400 configuration extraction tool, used to help with the NG2 conversion process. The tool will analyze the InterForm400 and extract the configuration incl. comprehensive usage details ...
    • What is output management?

      An Output Management Solution is designed to help you create, manage, and distribute all company output across any platform and any application. An intelligent output management solution is a hub where all output logic, designs, routines, and ...
    • How can I setup InterForm to do automatic merges?

      Merges between an input spooled file and a design (template) is usually done via the InterForm workflow. It is possible also to call InterForm commands from your own programs if you want to decide when this merge should be done. Most customers are ...