   =========================================================================
                           M I C R O   F O C U S

                     S E R V E R    E X P R E S S   5.0
   =========================================================================

                                  CSBIND
                                  ======

   TABLE OF CONTENTS
   =================

       INTRODUCTION
       SOURCE FILES
       COMPILING AND RUNNING THE DEMONSTRATION


   INTRODUCTION
   ============
   This demonstration is provided as an example of how to use the
   Client/Server Binding. The demonstration application prompts you
   for the name of a data file on your client machine, reads the
   data from this file and transfers it to the server where a
   copy of the file is created. The demonstration also shows you how
   to use the Client/Server Binding's Reduced File Transfer facility.

   Before you run this demonstration, make sure that you have set up
   the CSBIND environment as decribed in the chapter "Client/Server
   Binding" in your "Programmer's Guide to Communications".


   SOURCE FILES
   ============
   Below is a list of files required for the demonstration. The
   location of each file and whether the file needs to exist on the
   client, the server or both, is given.

                                                           Client or
   File Name    Description of File   Location             Server File
   -----------  -------------------   --------             -----------
   netxcli.cbl  Client program which  $COBDIR/demo/csbind  client
                prompts for the name        
                of the data file to
                be transferred. The
                program then calls 
                mfclient to establish
                communication with
                the server and
                transfer the data
                file.

   netxdemo.cfg The client/server     $COBDIR/demo/csbind  client
                binding configuration
                file for this    
                demonstration.                     
                             
   netxserv.cbl Server program which  $COBDIR/demo/csbind  server
                receives the data
                sent from the client
                program and writes it
                to the file 
                netxcpfl.dat. When
                all the data has been
                transferred this
                program sends a 
                message back to the
                client telling it the
                name of the data file
                and the directory 
                where it has been
                created.

     
   Notes:

   1.  On UNIX environments, filenames must be rendered in the case
       shown in the table above.

   2.  When creating client/server applications, you should be aware
       that there is a difference in byte ordering between machines
       based on different chips (for example, Intel and SPARC). To
       ensure that your client/server programs are portable, do not
       use COMP-5 data items; otherwise, you may encounter byte
       ordering problems on different machines. See your
       "Programmer's Guide to Writing Programs" for full information
       on possible portability issues.


   Compiling and Running The Demonstration
   =======================================
   This section explains which files need to be transferred to the
   server, how to compile and run the server and client files and how
   to run the demonstration.

    - In the steps below an example server name of filetran has been
      used.

    - It is assumed you are using the TCP/IP protocol.

    - Before running the demonstration, you must have a CCITCP2 
      daemon, with root privileges, running on your network and you
      must have set the CCITCP2 environment variable, on both the
      server and client machines, to point to the machine that the
      CCITCP2 daemon is running on.


   1. Transfer the following files to the server:

      (ascii files)
      -------------
      netxserv.cbl
      mfclisrv.cpy

      
   2. On the server:

      a. Set the CCITCP2 environment variable to point to the
         machine that the CCITCP2 daemon is running on.
      
      b. Compile the server program:

            cob -i netxserv.cbl.

      c. Start the server using the supplied configuration
         file:

            cobrun mfserver -s filetran

   3. On the client:

      a. Set the CCITCP2 environment variable to point to the
         machine that the CCITCP2 daemon is running on.

      b. Compile the client program:

            cob -i netxcli.cbl

      c. Start the client program using the supplied configuration
         file:

            cobrun netxcli netxdem.cfg

       d. Enter the name of the data file that you want to copy to
          the server machine. When a copy of the data file has been
          created on the server machine, the client program will 
          display a message indicating the name of the copied file
          (netxcpfl.dat) and the name of the directory in which it 
          has been created.

   4. When you have finished using the demonstration,
      you can terminate the server program from the client by 
      entering the following:
  
         cobrun mfcsmgr.int -s filetran -t


   =========================================================================
   Micro Focus is a registered trademark, and Server Express is a trademark,
   of Micro Focus International Limited. 
   =========================================================================
   Copyright (C) 1999-2001 Micro Focus International Limited. 
   All rights reserved.

