ibmi-brunch-learn

Announcement

Collapse
No announcement yet.

pass parameter from CL?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • pass parameter from CL?

    Hi,


    If I passed three parameter from the CL, how can I get it in RPGLE program?

    IN CL

    CALL PGM(PUGPFM) PARM(&var &var2 &var3)


    IN RPGLE


    *Entry plist
    parm var1
    parm var2
    parm var3



    But I'm getting error when compile the RPGLE

    The Result-Field operand var1 is not valid for the specified operation.




    Thanks!

  • #2
    Re: pass parameter from CL?

    Show us the code......Please for the RPG.

    you do have var1 2 and 3 defined Right??
    and they are not in a datastructure?


    jamie
    All my answers were extracted from the "Big Dummy's Guide to the As400"
    and I take no responsibility for any of them.

    www.code400.com

    Comment


    • #3
      Re: pass parameter from CL?

      Hi Jamief,

      There are not in data structure. actually, what I'm try to do is modify your code that shows me how to remove the physical member by date, without hard code the library and file name in the RPGLE program.

      I'm trying to make a simple command for user to put in those parameters and pass to the RPGLE program.

      Thanks!



      Originally posted by jamief
      Show us the code......Please for the RPG.

      you do have var1 2 and 3 defined Right??
      and they are not in a datastructure?


      jamie

      Comment


      • #4
        Re: pass parameter from CL?

        What var1 defined as? Alpha, decimal, packed ??

        Comment


        • #5
          Re: pass parameter from CL?

          Though we are very skilled at the art of RPG here. Well arrow more than me, but we cant help you fix your errors if we cant see the problems.

          you have to post the command // clp and RPG (at least the *entry plist and D specs of the incoming parms)
          for us to help you.

          thanks
          jamie
          All my answers were extracted from the "Big Dummy's Guide to the As400"
          and I take no responsibility for any of them.

          www.code400.com

          Comment


          • #6
            Re: pass parameter from CL?

            Thanks Jamief,

            i found the problem, because I haven't define the datastructure and it is working now!



            Originally posted by jamief
            Though we are very skilled at the art of RPG here. Well arrow more than me, but we cant help you fix your errors if we cant see the problems.

            you have to post the command // clp and RPG (at least the *entry plist and D specs of the incoming parms)
            for us to help you.

            thanks
            jamie

            Comment

            Working...
            X