Menu

How to use?

Nathaniel
2020-07-30
2020-08-03
  • Nathaniel

    Nathaniel - 2020-07-30

    I'm relatively new to RPG and could use some help getting this to work.

    What I've done so far:

    1. Created new source file: CVTRPGFREE
    2. Created CVTRPGFREC.clle, CVTRPGFREE.cmd, CVTRPGFRER.rpgle, CVTRPGFRP1.prtf
    3. Was able to compile all except for CVTRPGFRER.rpgle
    4. Tried to run the command: ===> CVTRPGFREE FROMMBR(MYPROGRAM1) FROMFILE(MYLIB/MYFILE) TOFILE(MYLIB/MYFILE) TOMBR(MYPROGRAM2)
    5. Received the message: Program CVTRPGFREE not found in library *LIBL.

    I know I'm not doing this correctly... could you please provide step-by-step on how to get this to work? Would much appreciate and am eager to try your software. Thank you.

     
  • Ewarwoowar

    Ewarwoowar - 2020-07-31

    Hi Nathaniel,

    You arent doing anything wrong...the source for CVTRPGFRER was corrupt, so was not compileable.

    Ive uploaded the correct source, so it should compile OK now, but please let me know if you are still experiencing problems.

     
  • Nathaniel

    Nathaniel - 2020-07-31

    I'm now able to compile CVTRPGFRER.rpgle, but am still having a problem.

    On the command line, I type: CVTRPGFREE
    F4

    I receive the command prompt screen, fill in the values, but when I hit Enter it says, "Program CVTRPGFREE not found in library *LIBL"

    My compiled objects are as follows:

    CVTRPGFREC.pgm.clle
    CVTRPGFRER.
    pgm.rpgle
    CVTRPGFRP1.file.prtf
    CVTRPGFREE
    cmd

    Thank you for your help so far.

     
  • Ewarwoowar

    Ewarwoowar - 2020-07-31

    When you compile the command, you have to specify PGM(CVTRPGFREC) to make the command call the CL program.

     
  • Nathaniel

    Nathaniel - 2020-08-03

    Thank you for your help! I got it to work in one of my environments, but when I try it in a different one, I receive the message: FMTOPT(*MAP) or FMTOPT(*NOCHK) required for copy.

    Edit: pretty easy fix (I'm still learning my way around AS400/RPG in case that isn't painfully obvious...) I added FMTOPT(*MAP) to the end of both CPYF commands in CVTRPGFREC.CLLE. After some testing it seems I had to add it to both for it to work.

    Thank you again for your help!

     

    Last edit: Nathaniel 2020-08-03
    • Ewarwoowar

      Ewarwoowar - 2020-08-03

      That is rather odd - there shouldn't be format differences...sounds like someone has created some non-standard source files, but if you've managed to get it to work, then I guess it can't be anything too weird.

      Happy to help, and let me know of you come across code that either doesn't convert or converts incorrectly.

       
MongoDB Logo MongoDB