home *** CD-ROM | disk | FTP | other *** search
/ Monster Media 1994 #1 / monster.zip / monster / OS2 / LNVREM.ZIP / LNREMSRC.EXE / LNH.H < prev    next >
Text File  |  1993-11-09  |  6KB  |  109 lines

  1. /************************************************************************/
  2. /*                                                                      */
  3. /* COPYRIGHT:  (c) Copyright International Business Machines            */
  4. /*             Corporation 1992                                         */
  5. /*                                                                      */
  6. /* NOTICE:  This program is supplied as an example only. No guarantees  */
  7. /*          of any kind, either explicit or implicit, apply to this     */
  8. /*          program.                                                    */
  9. /*                                                                      */
  10. /* FILE:                                                                */
  11. /*  LNH.H                                                               */
  12. /*                                                                      */
  13. /* VERSION:                                                             */
  14. /*  1.1                                                                 */
  15. /*                                                                      */
  16. /* DESCRIPTION:                                                         */
  17. /*  Common stuff for remote launch programs.                            */
  18. /*                                                                      */
  19. /* AUTHOR:                                                              */
  20. /*  C.R. McKelley                                                       */
  21. /*                                                                      */
  22. /* CHANGE HISTORY:                                                      */
  23. /*  1.0 08/09/93 CRM Original                                           */
  24. /*                                                                      */
  25. /************************************************************************/
  26. /* -------------------------------------------------------------------- */
  27. /*                            CONSTANTS                                 */
  28. /* -------------------------------------------------------------------- */
  29.  
  30.                                         /* Return codes                 */
  31. #define LN_RC_SUCCESSFUL        0       /* Successful                   */
  32. #define LN_RC_ERR_NOT_FOUND     4       /* Network name not found       */
  33. #define LN_RC_ERR_NO_AGENT      6       /* No system agent              */
  34. #define LN_RC_ERR_COMM          8       /* Communication error          */
  35. #define LN_RC_ERR_NO_CMD       10       /* No command string            */
  36. #define LN_RC_ERR_RCLI         12       /* RCLI or DosStart Session err */
  37. #define LN_RC_ERR_BAD_CMD     255       /* No valid command selected    */
  38.  
  39. #define MAXCMDS                50       /* Maximum num of remote cmds   */
  40. #define PINPUT_SIZE           150       /* Size of program input struct */
  41.  
  42. /* -------------------------------------------------------------------- */
  43. /*                      TYPEDEFS AND STRUCTURES                         */
  44. /* -------------------------------------------------------------------- */
  45.  
  46. typedef struct {                        /* Net ID and Sys ID structure  */
  47.    PSZ    NetID;
  48.    PSZ    SysID;
  49. } NIDSIDSTRUC;
  50.  
  51. typedef struct {                        /* Global command structure     */
  52.    PSZ    Cmd;                          /* Command pointer              */
  53.    PSZ    TimeOut;                      /* Time out value               */
  54.    PSZ    OutFile;                      /* Output file pointer          */
  55.    PSZ    InFile;                       /* Input file pointer           */
  56.    BOOL32 Sticky;                       /* Persistence flag             */
  57. } GCMDSTRUC;
  58.  
  59. typedef GCMDSTRUC *PGCMDSTRUC;          /* Pointer to type CMDSTRUC     */
  60.  
  61. typedef struct {                        /* Local command structure      */
  62.    PSZ    MenuText;
  63.    PSZ    Cmd;
  64.    PSZ    TimeOut;                      /* Time out value               */
  65.    PSZ    OutFile;                      /* Output file pointer          */
  66.    PSZ    InFile;                       /* Input file pointer           */
  67.    BOOL32 Sticky;                       /* Persistence flag             */
  68. } CMDSTRUC;
  69.  
  70. typedef CMDSTRUC *PCMDSTRUC;            /* Pointer to type CMDSTRUC     */
  71.  
  72. typedef struct {                        /* Node list structure          */
  73.    USHORT NumCmds;                      /* Number of commands           */
  74.    CMDSTRUC CmdStrucs[MAXCMDS];         /* Node identifiers             */
  75. } CMDLIST;
  76.  
  77. typedef CMDLIST *PCMDLIST;              /* Pointer to type CMDLIST      */
  78. /* -------------------------------------------------------------------- */
  79. /*                       FUNCTION PROTOTYPES                            */
  80. /* -------------------------------------------------------------------- */
  81.  
  82. MRESULT EXPENTRY NoCmdProc(HWND   hWndDlg,
  83.                            USHORT message, 
  84.                            MPARAM mp1, 
  85.                            MPARAM mp2);
  86.  
  87. MRESULT EXPENTRY NoAgentProc(HWND   hWndDlg,
  88.                              USHORT message, 
  89.                              MPARAM mp1, 
  90.                              MPARAM mp2);
  91.  
  92. MRESULT EXPENTRY RCLIErrProc(HWND   hWndDlg,
  93.                              USHORT message, 
  94.                              MPARAM mp1, 
  95.                              MPARAM mp2);
  96.  
  97. MRESULT EXPENTRY CmdListProc(HWND hWndDlg,
  98.                              USHORT message,
  99.                              MPARAM mp1,
  100.                              MPARAM mp2);
  101.  
  102. ULONG APIENTRY GetNetIDSysID(PSZ         LongName,
  103.                              NIDSIDSTRUC *pNIDSIDStruc);
  104.  
  105. ULONG APIENTRY GetCmdString(PGCMDSTRUC *pCmdStruct);
  106.  
  107. ULONG APIENTRY DNDecode(PVOID       SysObjectDN,
  108.                         NIDSIDSTRUC *pNIDSIDStruc);
  109.