10 pts.
 Can I change c0001copybook in RPG?
in rpg c0001 is a standard copybook.if i want to make a new program then can i use this copybook.and for my program some modification is necessary...so can i change this copybook program

Software/Hardware used:
ASKED: April 20, 2012  8:07 AM
UPDATED: April 20, 2012  6:59 PM

Answer Wiki:
You can use that copybook but if you try to modify it then you have to check the impact of that copybook to other programs. Otherwise you can crate the same copy-book with different name and do the modification as you want and use that copybook in your program.
Last Wiki Answer Submitted:  April 20, 2012  10:00 am  by  ssssssssssssssss   80 pts.
All Answer Wiki Contributors:  ssssssssssssssss   80 pts.
To see all answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _


 

Changing a copy book has no effect…the effect occurs when a program that uses it is recompiled.

 44,630 pts.

 

You can probably change the /COPY book to supply the statements that you need without affecting any other program that needs the same /COPY book.

You could place a /DEFINE statement in your program source to define a condition name, placing the statement just before the /COPY statement. In the /COPY book, you could put a /IF Condition-Expression statement to test for your new defined condition name to put your changes in your program. Other programs that don’t define the same condition name would continue to get the old statements that aren’t included in your new structure.

Tom

 110,135 pts.