Re: CREATEPROCESS and other questions... - Hewlett Packard

This is a discussion on Re: CREATEPROCESS and other questions... - Hewlett Packard ; Mike There is an intrinsic (HPCICOMMAND) that will let you stream a job or do just about any other MPE command from within your program. The file name parameter can be as long as necessary to specify the name of ...

+ Reply to Thread
Results 1 to 3 of 3

Thread: Re: CREATEPROCESS and other questions...

  1. Re: CREATEPROCESS and other questions...

    Mike

    There is an intrinsic (HPCICOMMAND) that will let you stream a job
    or do just about any other MPE command from within your program.
    The file name parameter can be as long as necessary to specify the
    name of the executable you wish to launch, provided that you have
    security access to do it. To check the security do a listf file,4
    on the file and it will show you your access.

    How this helps

    Robert Schlosser
    Global Business Systems
    Premier Farnell plc
    T 864 487-1362
    F 864.487.1904
    E rschlosser@premierfarnell.com
    Your #1 source for RoHS compliant products & information.
    www.newark.com



    -----Original Message-----
    From: HP-3000 Systems Discussion [mailto:HP3000-L@RAVEN.UTC.EDU]On
    Behalf Of Michael Mileusnich
    Sent: Monday, July 07, 2008 3:27 PM
    To: HP3000-L@RAVEN.UTC.EDU
    Subject: [HP3000-L] CREATEPROCESS and other questions...


    Hello,

    I am porting a C application over to MPE/iX and I have some questions
    regarding CREATEPROCESS. It seems CREATEPROCESS only lets me launch an
    executable program. What do I need to use if I wanted to STREAM a job or
    run an internal command such as a LISTFILE? Also, when using CREATEPROCESS,
    the executable in which I want to launch will only launch if the executable
    is in the same group as my application.

    Thanks
    Mike Miles

    * To join/leave the list, search archives, change list settings, *
    * etc., please visit http://raven.utc.edu/archives/hp3000-l.html *


    https://www.mailcontrol.com/sr/wQw0zmjPoHdJTZGyOCrrhg==
    7W8j47gMdxBTxvs8OPTIwqklWXhOt302A3zwbO5JA==
    Click on the link above to report this email as spam to BlackSpider.


    ***************************Disclaimer************* **************
    The contents of this e-mail and any file transmitted with it are confidential and intended solely for the individual or entity to whom they are addressed. The content may also contain legal, professional or other privileged information. If you received this e-mail in error, please destroy it immediately. You should not copy or use it for any purpose nor disclose its contents to any other person. The views stated herein do not necessarily represent the view of the Company. Please ensure you have adequate virus protection before you open or detach any documents from this transmission. The Company does not accept any liability for viruses.
    Premier Farnell plc
    150 Armley Road Leeds
    LS12 2QQ
    Telephone +44 (0) 870 129 8608
    Fax +44 (0) 870 129 8610
    Registered in England
    Company Number 876412
    Registered Office: Farnell House, Forge Lane, Leeds LS12 2NE ************************************************** **********

    * To join/leave the list, search archives, change list settings, *
    * etc., please visit http://raven.utc.edu/archives/hp3000-l.html *


  2. Re: CREATEPROCESS and other questions...

    When I use the HPCICOMMAND I am passing it my command plus a \n or \r and I
    receive the following error:

    **** UNEXPECTED ESCAPE CODE ENCOUNTERED IN SYSTEM CODE, ESCAPE CODE = 9132


    On Mon, Jul 7, 2008 at 2:35 PM, wrote:

    > Mike
    >
    > There is an intrinsic (HPCICOMMAND) that will let you stream a job
    > or do just about any other MPE command from within your program.
    > The file name parameter can be as long as necessary to specify the
    > name of the executable you wish to launch, provided that you have
    > security access to do it. To check the security do a listf file,4
    > on the file and it will show you your access.
    >
    > How this helps
    >
    > Robert Schlosser
    > Global Business Systems
    > Premier Farnell plc
    > T 864 487-1362
    > F 864.487.1904
    > E rschlosser@premierfarnell.com
    > Your #1 source for RoHS compliant products & information.
    > www.newark.com
    >
    >
    >
    > -----Original Message-----
    > From: HP-3000 Systems Discussion [mailto:HP3000-L@RAVEN.UTC.EDU]On
    > Behalf Of Michael Mileusnich
    > Sent: Monday, July 07, 2008 3:27 PM
    > To: HP3000-L@RAVEN.UTC.EDU
    > Subject: [HP3000-L] CREATEPROCESS and other questions...
    >
    >
    > Hello,
    >
    > I am porting a C application over to MPE/iX and I have some questions
    > regarding CREATEPROCESS. It seems CREATEPROCESS only lets me launch an
    > executable program. What do I need to use if I wanted to STREAM a job or
    > run an internal command such as a LISTFILE? Also, when using
    > CREATEPROCESS,
    > the executable in which I want to launch will only launch if the executable
    > is in the same group as my application.
    >
    > Thanks
    > Mike Miles
    >
    > * To join/leave the list, search archives, change list settings, *
    > * etc., please visit http://raven.utc.edu/archives/hp3000-l.html *
    >
    >
    > https://www.mailcontrol.com/sr/wQw0zmjPoHdJTZGyOCrrhg==
    > 7W8j47gMdxBTxvs8OPTIwqklWXhOt302A3zwbO5JA==
    > Click on the link above to report this email as spam to BlackSpider.
    >
    >
    > ***************************Disclaimer************* **************
    > The contents of this e-mail and any file transmitted with it are
    > confidential and intended solely for the individual or entity to whom they
    > are addressed. The content may also contain legal, professional or other
    > privileged information. If you received this e-mail in error, please destroy
    > it immediately. You should not copy or use it for any purpose nor disclose
    > its contents to any other person. The views stated herein do not necessarily
    > represent the view of the Company. Please ensure you have adequate virus
    > protection before you open or detach any documents from this transmission.
    > The Company does not accept any liability for viruses.
    > Premier Farnell plc
    > 150 Armley Road Leeds
    > LS12 2QQ
    > Telephone +44 (0) 870 129 8608
    > Fax +44 (0) 870 129 8610
    > Registered in England
    > Company Number 876412
    > Registered Office: Farnell House, Forge Lane, Leeds LS12 2NE
    > ************************************************** **********
    >
    >


    * To join/leave the list, search archives, change list settings, *
    * etc., please visit http://raven.utc.edu/archives/hp3000-l.html *


  3. Re: CREATEPROCESS and other questions...

    Mike wrote:

    > When I use the HPCICOMMAND I am passing it my command plus a \n or \r

    and > I receive the following error:
    > **** UNEXPECTED ESCAPE CODE ENCOUNTERED IN SYSTEM CODE, ESCAPE CODE =

    9132

    I don't know what you're doing wrong. In the C language, \r is the
    correct way to get a carriage return, so that is the correct way to
    terminate your command.

    My C is a little rusty, but here's a working program that should help.

    -----cut here-----
    #include
    #pragma intrinsic HPCICOMMAND
    int main(void)
    {
    short cmderror;
    HPCICOMMAND("SHOWTIME\r", &cmderror);
    if (!cmderror)
    return EXIT_SUCCESS;
    else
    return EXIT_FAILURE;
    }
    -----cut here-----

    Walter

    Walter J. Murray

    * To join/leave the list, search archives, change list settings, *
    * etc., please visit http://raven.utc.edu/archives/hp3000-l.html *


+ Reply to Thread