|
(char *)QP0W_Job_ID_T.jobname (yeah, I know, use a real variable name )
(char *)QP0W_Job_ID_T.jobid
HTH Vern
Ok I found the API call and have NO idea how to use it. The documentation and the header file seem to conflict.
I call it as follows:
QUSRJOBI( &(JOBI300 type structure ), sizeof(JOBI0300), "JOBI0300", "<some job name>", "16 spaces" );
I assertained the "some job name" and the "16 spaces" from what I did find out this API call from inside some
RPG code.
This does not work at all, and I get a "Job name specified not valid" before I get a CPF code ( Im assuming something
like a core dump in UNIX ).
I was assuming that I would put into the last 2 parameters for this API ( Qualified job name and Internal Job Identifier ) that
values returned from Qp0wGetJobID( pid, job_id_structure ), but I guess that is not the case.
Any idea how to fill in the paramters for QUSRJOBI, and maybe a snipet of C code of how to go to a pid returned by
spawn(), to getting a launched job's information?
TIA!
Walt Fles
Tom Daly wrote:
You can use them in C, the headers are in QSYSINC/H.
| -----Original Message-----
| From: Walt Fles [mailto:wfles@xxxxxxxxxxx]
| Sent: Friday, June 04, 2004 09:38
| To: Midrange Systems Technical Discussion
| Subject: Re: C access to a job's spooled files
|
|
| It looked like to me those are CL API calls, not C level, | am I right?
|
|
| Tom Daly wrote:
|
| >You can use QUSRJOBI to retrieve info abou tthe job and | QUSLSPL can be used
| >to return a list of spoolfiles for a job. The Work | Management API book and
| >the Print API book will help with these.
| >
| >
| >Tom D.
| >
| > | -----Original Message-----
| > | From: Walt Fles [mailto:wfles@xxxxxxxxxxx]
| > | Sent: Thursday, June 03, 2004 17:14
| > | To: Midrange Systems Technical Discussion
| > | Subject: C access to a job's spooled files
| > |
| > |
| > | All,
| > | I know if I spawn a job I can do a "Qp0wGetJobID" from | within C,
| > | but can I use that information to find a job's information | > | and also the | > | spooled files of the job,
| > | once I detect that the job has completed ( ie, via a | waitpid() ).
| > |
| > | I would like to have access to a spawned job's spooled | > | files from within | > | C, not CL, COBOL or RPG.
| > |
| > |
| > |
| > | TIA!
| > |
| > |
| > |
| > | --
| > | This is the Midrange Systems Technical Discussion | > | (MIDRANGE-L) mailing list
| > | To post a message email: MIDRANGE-L@xxxxxxxxxxxx
| > | To subscribe, unsubscribe, or change list options,
| > | visit: http://lists.midrange.com/mailman/listinfo/midrange-l
| > | or email: MIDRANGE-L-request@xxxxxxxxxxxx
| > | Before posting, please take a moment to review the archives
| > | at http://archive.midrange.com/midrange-l.
| > |
| > |
| >
| >--
| >This is the Midrange Systems Technical Discussion | (MIDRANGE-L) mailing list
| >To post a message email: MIDRANGE-L@xxxxxxxxxxxx
| >To subscribe, unsubscribe, or change list options,
| >visit: http://lists.midrange.com/mailman/listinfo/midrange-l
| >or email: MIDRANGE-L-request@xxxxxxxxxxxx
| >Before posting, please take a moment to review the archives
| >at http://archive.midrange.com/midrange-l.
| >
| >
| >
|
| --
| This is the Midrange Systems Technical Discussion | (MIDRANGE-L) mailing list
| To post a message email: MIDRANGE-L@xxxxxxxxxxxx
| To subscribe, unsubscribe, or change list options,
| visit: http://lists.midrange.com/mailman/listinfo/midrange-l
| or email: MIDRANGE-L-request@xxxxxxxxxxxx
| Before posting, please take a moment to review the archives
| at http://archive.midrange.com/midrange-l.
|
|
-- This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe, unsubscribe, or change list options, visit: http://lists.midrange.com/mailman/listinfo/midrange-l or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take a moment to review the archives at http://archive.midrange.com/midrange-l.
-- This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe, unsubscribe, or change list options, visit: http://lists.midrange.com/mailman/listinfo/midrange-l or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take a moment to review the archives at http://archive.midrange.com/midrange-l.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.