AS400 RPG Program Calling

Does any one know how to call AS/400 RPG program in Flow Service or using Java Service in webMethods 6.0.1?

Hi GV,

You can use the AS/400 tool kit for Java which comes in the form of jt400.jar. This is even available on the IBM site or for that matter you can always do a google search.
This jar has API’s with which you can call RPG programs on AS/400.

e.g.
AS400 system = new AS400("<ip>","<username>","<password>");
etc.
Hope this helps.

regds
Radhika

Hi Radhika,

Thanks for your info on calling RPG program.

I am already using the jt400.jar and the AS400 class for profile swaping. But here the problem is we have to pass the username and the other system details when ever you want to call this.

Is there any other method which can be used calling the program using the existing database alias to the AS/400.

If you can have any info this would be really great.

Thanks for your response.

-GV

Hi Radhika,

I also got some information on this when browsing the AS/400 Java tool kit docs.

ProgramCall class can be useed to call the program but still we do have to pass the AS400 class as an input param to this.

Thanks,
-GV

Hi GV,

I don’t think i am very clear about the problem you have. You need to call some RPG program on the AS/400 system but you don’t want to hardcode the program name in the call. Is that what it is ? Or is is that the program name is not known ? Could you please elaborate on this ?

regds
Radhika

Yeah, I don’t want to hardcode or pass the System and User details each and every time, when ever I want to call the RPG programs from AS/400.

I know the program name, any way that we have to hardcode or read from property file.

Only the thing is I don’t want to pass the system and user parameters when we calling the RPG program using the AS400 and ProgramCall classes.

I hope this is clear.

Thanks,
-GV

Then you may want to create a service that contains only the connection/configuration info to be reused.

Any way Thank You Radhika.

Rgds,
-GV