• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

invoking as/400 session from cold fusion

Guest
Jun 13, 2006 Jun 13, 2006

Copy link to clipboard

Copied

hello,
i have a as/400 system in which there is program screen i would like to invoke and input some values into, is it possible using cold fusion. ...any ideas....thanks
TOPICS
Advanced techniques

Views

340

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Participant ,
Jun 14, 2006 Jun 14, 2006

Copy link to clipboard

Copied

LATEST
If you are really trying to fill in screen fields, assuming you are using Iseries Access for Windows Workstation program as an emulator, you would need to write an API program using DDE or EHLLAPI. ColdFusion could cfexecute this program if the Workstation emulator interface was on the Coldfusion server itself.

see http://publib.boulder.ibm.com/infocenter/pcomhelp/index.jsp?topic=/com.ibm.pcomm.doc/emulator_progra...

If you are actually just trying to execute an AS/400 program it was covered in this thread:

http://www.adobe.com/cfusion/webforums/forum/messageview.cfm?catid=7&threadid=793131&arctab=arc

Here's an example of how to run an AS/400 program from within a CF web page:

<CFQUERY name="CallProg" datasource="#dataSource#" username="#userName#" password="#userPassword#">
CALL QSYS.QCMDEXC('CALL YOURLIB/YOURPROG', 0000000021.00000)
</CFQUERY>

Be sure to count the exact number of characters in the actual command and place that number in the second parameter.

So you might test that with something like the following:

<CFQUERY NAME="test1" DATASOURCE="#dataSource#">
CALL QSYS.QCMDEXC('CALL QSYS/SNDMSG MSG(TEST1) TOUSR(yourid)', 0000000041.00000)
</cfquery>

This is better than the method I had used before of using cfexecute to invoke ftp with a script file containing a line like:

quote rcmd SNDMSG MSG(TEST2) TOUSR(yourid)

For creating a batch you may find it useful to learn how to create an inline data file that is submitted with SBMDBJOB.



Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation