× 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.



That's kind of what I was thinking about, but how to I create one command that will display prompts for parameters that vary by what the current OS version is. I know you can do dependencies on the command parms, but I don't see where I can access the current OS release inside the command before I call the command processor program ( like you have below).

I want the command prompt to look like the following according to your example, all without having to change the command for each OS release.

When run on a release before V5R2:

Object Name . . . . . . . . _____
Library . . . . . . . . . . . . _____

When run on release V5R2:

Object Name . . . . . . . . _____
Library . . . . . . . . . . . . _____
Object Type . . . . . . . . . _____

And when run on release V5R3:

Object Name . . . . . . . . _____
Library . . . . . . . . . . . . _____
Object Type . . . . . . . . . _____
New V5R3 parm . . . . . _____

and on release 6.1

Object Name . . . . . . . . _____
Library . . . . . . . . . . . . _____
Object Type . . . . . . . . . _____
New V5R3 parm . . . . . _____
Extension . . . . . . . . . . . __________

I am just not seeing an easy way to do this. I think if I can get the command prompts to work by release, I can get the API call to work.

Thanks

On 10/19/2010 4:39 PM, Dennis Lovelady wrote:
You mean like this?

d api_program PR extpgm('API_NAME')
d objname 10 Const
d objlibr 10 Const
* Added at V5R2
d objtype 10 Const Options(*NoPass)
* Added at V5R3
d errstr LikeDS(errorStruct)
d Options(*VarSize: *NoPass)
* Added at i6.1
D extension 20 Const Options(*NoPass)

D currentVRM S 6

// If currentVRM = VxRyMz

Select ;
When currentVRM>= CON_I6_1 ;
api_program(parm1: parm2: type: errStr: ext) ;
When currentVRM>= CON_V5R3 ;
api_program(parm1: parm2: type: errStr) ;
When currentVRM>= CON_V5R2 ;
api_program(parm1: parm2: type) ;
Other ;
api_program(parm1: parm2) ;
EndSL ;



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

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.