home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / cenvi23.zip / PROCLIST.CMD < prev    next >
OS/2 REXX Batch file  |  1995-03-28  |  687b  |  18 lines

  1. EXTPROC CEnvi2
  2. /***************************************************************************
  3.  *** ProcList.cmd - CEnvi2 program to list the names of processes running ***
  4.  *** ver.2          and the ID of each process.                          ***
  5.  ***************************************************************************/
  6.  
  7. PList = ProcessList()
  8. assert( NULL != PList )
  9. Count = 1 + GetArraySpan(PList)
  10. printf(" ID   Parent   name      FullName\n");
  11. printf("----  ------   --------  -------------\n");
  12. for ( i = 0; i < Count; i++ ) {
  13.    printf(" %-6d %-6d %-9s %s\n",
  14.           PList[i].id,PList[i].parent,
  15.           SplitFileName(PList[i].name).name,PList[i].name)
  16. }
  17.  
  18.