× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



If you want to send multiple data items (a structure) in a single parameter
you have a couple ways to go using Toolbox objects.  First, you can use the
Toolbox converters to convert the items one at a time, sticking them into
the same byte array.  Your code would is responsible for making sure the
byte array is correctly formed.  Second, you could use a Toolbox
RecordFormat object.  That object is a collection of converters.  You stick
the proper types in the record format, then tell the object to dump out a
byte array that your code sends to the server.  An example is at
http://publib.boulder.ibm.com/pubs/html/as400/v5r1/ic2924/info/rzahh/javadoc/DQProducerExample.html.

 A third choice is PCML.  This is an XML language for calling programs.  In
XML you describe the format of the parameter, then PCML does the work of
calling the program.  See the PCML section of the Toolbox pub
(http://publib.boulder.ibm.com/pubs/html/as400/v5r1/ic2924/info/rzahh/pcml.htm)

for more information.

David Wall
AS/400 Toolbox for Java




                      OKogan@capitalfac
                      tors.com                 To:       java400-l@midrange.com
                      Sent by:                 cc:
                      java400-l-admin@m        Subject:  RE: Java to RPG 
question
                      idrange.com


                      02/15/2002 03:57
                      PM
                      Please respond to
                      java400-l





Dave, Thanks for your reply. I think, I have to further describe my
question. I've been able to send a few parameters to the RPG and get them
back. What I'm trying to do is to send data structure of fields with
different attributes, maybe even externally described DS(is that possible
at all?).

Thanks again, Oleg.

-----Original Message-----
From: Dave Wall [mailto:dawall@us.ibm.com]
Sent: Friday, February 15, 2002 4:25 PM
To: java400-l@midrange.com
Subject: Re: Java to RPG question


I can help a little.  Conversion classes in the IBM Toolbox for Java can
help convert between Java and iSeries formats.  For example, you use the
AS400PackedDecimal class to convert between a Java double and an iSeries
packed decimal number.  The following converts a Java double number into
iSeries packed decimal format and stuff them into a byte array.  It then
reverses the process.  It grabs the numbers out of the bytes byte array and
converts them back into Java numbers.










The information transmitted by the following E-Mail is intended only for
the addressee and may contain confidential and/or privileged material. Any
interception, review, retransmission, dissemination, or other use, or
taking any action upon this information by persons or entities other than
the intended recipient is prohibited by law and may subject them to
criminal or civil liability. If you received this communication in error,
please contact us immediately at 954-730-2900 ext. 3600 and delete the
communication from any computer or network system.


_______________________________________________
This is the Java Programming on and around the iSeries / AS400 (JAVA400-L)
mailing list
To post a message email: JAVA400-L@midrange.com
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/cgi-bin/listinfo/java400-l
or email: JAVA400-L-request@midrange.com
Before posting, please take a moment to review the archives
at http://archive.midrange.com/java400-l.







As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.