Changeset 20
- Timestamp:
- Oct 7, 2014, 4:25:50 PM (11 years ago)
- Location:
- rxutilex/trunk
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
rxutilex/trunk/FUNCTIONS
r19 r20 344 344 Sys2QueryForegroundProcess 345 345 346 Queries the PID of the current foreground process. 346 Queries the PID of the current foreground process. (Note that this is not 347 necessarily the same as the process which is calling this function, which 348 could, for example, be running in the background and/or as a child of the 349 foreground process.) 347 350 348 351 REXX ARGUMENTS: None … … 369 372 370 373 Queries information about the specified process. 374 375 Specifying a process ID of 0 will return the information for the 376 current process (that is, the process calling this function); note that 377 this requires the second parameter to specify that the identifier is in 378 fact a process ID ('P' or 'H') rather than an executable name. 371 379 372 380 REXX ARGUMENTS: -
rxutilex/trunk/Makefile
r18 r20 16 16 17 17 $(NAME).dll : $(NAME).obj 18 makedesc -D"Ext raREXX Utility Functions" -N"Alex Taylor" -V"^#define=SZ_VERSION,rxutilex.c" $(NAME).def18 makedesc -D"Extended REXX Utility Functions" -N"Alex Taylor" -V"^#define=SZ_VERSION,rxutilex.c" $(NAME).def 19 19 $(LINK) $(LFLAGS) $(NAME).obj $(NAME).def $(LIBS) /O:$@ 20 20 # @dllrname.exe $@ CPPOM30=OS2OM30 /Q /R -
rxutilex/trunk/rxutilex.c
r18 r20 73 73 #define SZ_LIBRARY_NAME "RXUTILEX" // Name of this library 74 74 #define SZ_ERROR_NAME "SYS2ERR" // REXX variable used to store error codes 75 #define SZ_VERSION "0. 0.5" // Current version of this library75 #define SZ_VERSION "0.1.0" // Current version of this library 76 76 77 77 // Maximum string lengths... … … 1956 1956 CHAR szName[ CCHMAXPATH ] = {0}, // Fully-qualified name of process 1957 1957 szNoExt[ CCHMAXPATH ] = {0}; // Program name without extension 1958 PPIB ppib; // pointer to current process info block 1958 1959 PSZ pszCurrent, // Program name of a queried process 1959 1960 c; // Pointer to substring … … 1964 1965 APIRET rc; // Return code 1965 1966 1967 1968 // Use current process when PID is 0 and program name is not specified 1969 if (( pszProgram == NULL ) && ( *pulPID == 0 )) { 1970 rc = DosGetInfoBlocks( NULL, &ppib ); 1971 if ( rc != NO_ERROR ) { 1972 WriteErrorCode( rc, "DosGetInfoBlocks"); 1973 return ( rc ); 1974 } 1975 *pulPID = ppib->pib_ulpid; 1976 } 1966 1977 1967 1978 #ifdef USE_DQPS -
rxutilex/trunk/rxutilex.def
r18 r20 1 1 LIBRARY RXUTILEX INITINSTANCE TERMINSTANCE 2 2 DATA MULTIPLE NONSHARED 3 DESCRIPTION '@#Alex Taylor:0. 0.5#@##1## 21 Sep 2014 16:45:48REINFORCE::::::@@Extra REXX Utility Functions'3 DESCRIPTION '@#Alex Taylor:0.1.0#@##1## 7 Oct 2014 22:42:18 REINFORCE::::::@@Extra REXX Utility Functions' 4 4 5 5 EXPORTS Sys2LoadFuncs -
rxutilex/trunk/testlib.cmd
r17 r20 11 11 12 12 say Sys2QueryProcess( 40, 'P') 13 say 'Current process:' Sys2QueryProcess( 0, 'P') 13 14 14 15 pc = Sys2QueryProcessList('procs.') 15 16 say pc 'processes found.' 17 /* 16 18 do i = 1 to procs.0 17 19 say procs.i 18 20 end 21 */ 19 22 say 'Current foreground process:' Sys2QueryForegroundProcess() 20 23 /*
Note:
See TracChangeset
for help on using the changeset viewer.