Unconfigured Ad Widget

Collapse

Announcement

Collapse
No announcement yet.

Convert C Prototype to RPG

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

  • Convert C Prototype to RPG

    I need to interface our payroll program with Vertex Q Series payroll tax software. The Vertex functions are written in C and our payroll program is in RPG. I am not proficient in the C language so I'm struggling to prototype the functions in my RPG program. Here's an example:

    PREFIX int POSTFIX VprtXML(tVprtConn lConnHdl,
    void **pSession,
    char *XmlBuf,
    char *XmlResult,
    long *pResultSize);

    Here's what I tried (I hope I'm on the right track) but the 2nd parameter is not correct. What is the proper way to define the "void **pSession" parm? Do the others look correct?


    D VprtXML PR EXTPROC(*CWIDEN:'VprtXML')
    D pConn * value options(*string)
    D pSession * value options(*string)
    D pXmlBuf * value options(*string)
    D pXmlResult * value options(*string)
    D pResultSize 10I 0


    Thanks,

    Larry

  • #2
    Maybe you have already read this document, but Barbara Morris, IBM's expert on the topic, has recently updated her paper describing the challenges surrounding the conversion of definitions between C and RPG:



    I can't really help you, other than pointing you to this documentation.
    Well, I can make educated guesses, but so can you, I'm sure. :-)

    Comment

    Working...
    X