midrange.com code scratchpad
Name:
errNo
Scriptlanguage:
Plain Text
Tabwidth:
4
Date:
10/13/2010 06:00:30 pm
IP:
Logged
Description:
The user was to lazy to give a description
Code:
  1.      /*=============================================================================================  
  2.      /*   Notes                                                                                       
  3.      /*=============================================================================================  
  4.                                                                                                       
  5.      /* Compile with ACTGRP(*CALLER)                                                                  
  6.                                                                                                       
  7.      /*=============================================================================================  
  8.      /*   Control Specifications                                                                      
  9.      /*=============================================================================================  
  10.                                                                                                       
  11.      H NoMain                                                                                         
  12.      H BndDir('MCSERV')                                                                               
  13.      H Option(*NODEBUGIO : *NOUNREF)                                                                  
  14.      H ExtBinInt                                                                                      
  15.                                                                                                       
  16.      /*=============================================================================================  
  17.      /*   File Specifications                                                                         
  18.      /*=============================================================================================  
  19.                                                                                                       
  20.                                                                                                       
  21.      /*=============================================================================================  
  22.      /*   Prototype Specifications                                                                    
  23.      /*=============================================================================================  
  24.                                                                                                       
  25.       /Include QRpgCbSrc,SVS9998                                                                      
  26.                                                                                                       
  27.      /*=============================================================================================  
  28.      /*   Data Specifications                                                                         
  29.      /*=============================================================================================  
  30.                                                                                                       
  31.      /*---------------------------------------------------------------------------------------------  
  32.      /*   Data Structure Specifications                                                               
  33.      /*---------------------------------------------------------------------------------------------  
  34.                                                                                                       
  35.                                                                                                       
  36.      /*---------------------------------------------------------------------------------------------  
  37.      /*   Array Specifications                                                                        
  38.      /*---------------------------------------------------------------------------------------------  
  39.                                                                                                       
  40.                                                                                                       
  41.      /*---------------------------------------------------------------------------------------------  
  42.      /*   Indicator Specifications                                                                    
  43.      /*---------------------------------------------------------------------------------------------  
  44.                                                                                                       
  45.                                                                                                       
  46.      /*---------------------------------------------------------------------------------------------  
  47.      /*   Standalone Data Specifications                                                              
  48.      /*---------------------------------------------------------------------------------------------  
  49.                                                                                                       
  50.                                                                                                       
  51.      /*---------------------------------------------------------------------------------------------  
  52.      /*   Constant Specifications                                                                     
  53.      /*---------------------------------------------------------------------------------------------  
  54.                                                                                                       
  55.                                                                                                       
  56.      /*#############################################################################################  
  57.      /*   errNo - errNo C Function interface for RPGLE                                                
  58.      /*#############################################################################################  
  59.                                                                                                       
  60.      P errNo...                                                                                       
  61.      P                 B                   Export                                                     
  62.                                                                                                       
  63.      /*+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
  64.      /* Procedure Interface                                                                           
  65.      /*+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
  66.                                                                                                       
  67.      D errNo           PI            10I 0                                                            
  68.      D setErrNoValue                 10I 0 Const Options(*NOPASS)                                     
  69.                                                                                                       
  70.      /*=============================================================================================  
  71.      /* Procedure Prototype Specifications                                                            
  72.      /*=============================================================================================  
  73.                                                                                                       
  74.      D errNo_Builtin   PR              *   ExtProc('__errno')                                         
  75.                                                                                                       
  76.      /*=============================================================================================  
  77.      /* Procedure Data Specifications                                                                 
  78.      /*=============================================================================================  
  79.                                                                                                       
  80.                                                                                                       
  81.      /*---------------------------------------------------------------------------------------------  
  82.      /* Procedure Data Structure Specifications                                                       
  83.      /*---------------------------------------------------------------------------------------------  
  84.                                                                                                       
  85.                                                                                                       
  86.      /*---------------------------------------------------------------------------------------------  
  87.      /* Procedure Array Specifications                                                                
  88.      /*---------------------------------------------------------------------------------------------  
  89.                                                                                                       
  90.                                                                                                       
  91.      /*---------------------------------------------------------------------------------------------  
  92.      /* Procedure Indicator Specifications                                                            
  93.      /*---------------------------------------------------------------------------------------------  
  94.                                                                                                       
  95.                                                                                                       
  96.      /*---------------------------------------------------------------------------------------------  
  97.      /* Procedure Standalone Data Specifications                                                      
  98.      /*---------------------------------------------------------------------------------------------  
  99.                                                                                                       
  100.      D errNoBase       S               *                                                              
  101.      D errNoValue      S             10I 0 Based(errNoBase)                                           
  102.                                                                                                       
  103.      /*---------------------------------------------------------------------------------------------  
  104.      /* Procedure Constant Specifications                                                             
  105.      /*---------------------------------------------------------------------------------------------  
  106.                                                                                                       
  107.                                                                                                       
  108.      /*+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
  109.      /* Procedure Code                                                                                
  110.      /*+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++  
  111.                                                                                                       
  112.       /Free                                                                                           
  113.                                                                                                       
  114.        If %Parms = 1;                                                                                 
  115.           errNoBase = errNo_BuiltIn();                                                                
  116.           errNoValue = setErrNoValue;                                                                 
  117.        EndIf;                                                                                         
  118.                                                                                                       
  119.        errNoBase = errNo_BuiltIn();                                                                   
  120.                                                                                                       
  121.        Return errNoValue;                                                                             
  122.                                                                                                       
  123.       /End-Free                                                                                       
  124.                                                                                                       
  125.      P errNo...                                                                                       
  126.      P                 E                                                                              
  127.                                                                                                       
  128.        //===========================================================================================  
© 2004-2019 by midrange.com generated in 0.008s valid xhtml & css