[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

using null parameters in cl program

Posted on 2004-08-08
4
Medium Priority
?
681 Views
Last Modified: 2008-02-01
Hi, I want to ask if and how can I use a parameters in a CL program which might not to be passed ?

I mean that I might call this CL program without using these last parameters,
and if I do so, if and how can I use these parameters in the CL program ?

until now I allways received the message "Pointer not set for location referenced." when I tryed using these parms.

Thank.
0
Comment
Question by:ams6
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 6

Accepted Solution

by:
dedy_djajapermana earned 600 total points
ID: 11746468
hi,

you can create a command to call the program. with command, you can give a default value when the parameters are not provided.

cheers,
dd
0
 

Author Comment

by:ams6
ID: 11750250
Thanks,
and my contiuation problem is that i want to add parameters to an existing cl program without changing the programs which called to that cl prog.
0
 
LVL 14

Expert Comment

by:daveslater
ID: 11784083
Hi
a work around that I have used in the past is to:
Rename the old cl to say PGM CLA.
Create the new CL say PGMCLB the same as the iold CL but with then new parms
then create an RPG (or RPGLE) program under the original CL name.
With the RPG you can then test for the number of parms passed and call the relevent CL.

Dave
0
 
LVL 27

Expert Comment

by:tliotta
ID: 11837121
ams6:

First question -- Is it a CL program or ILE CL program? If it's CL, then a command is your only option, AFAIK.

But by compiling it as ILE CL, you don't need a command. The program can be called directly and handle optional parms fine.

Tom
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Are you looking for the options available for exporting EDB files to PST? You may be confused as they are different in different Exchange versions. Here, I will discuss some options available.
This month, Experts Exchange sat down with resident SQL expert, Jim Horn, for an in-depth look into the makings of a successful career in SQL.
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…

649 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question