DELPHI 3
  /





CLIENT/SERVER

Developer's Guide
with Delphi 3

Ken Henderson

201 West 103rd Street
Indianapolis, Indiana 46290


DELPHI 3

  /




 



  
1997


 32.973.2
38

 ""

.  .. 

     .. , .. .. ,
.. , .. , .. 

  ..  ()

      ""  
 : 261-5936, 261-5643,  227-1456

Internet: marin@dcp.kiev.ua, http://www.dcp.kiev.ua

      : diamail@dcp.kiev.ua


 : -419, 117419, / 10, ./ 955-5288, 955-5397
 : -6, 252006, / 100, ./ 268-6027, 230-2667, 261-9287

, .

38    Delphi 3   /.  . : .  .  . : , 1997.
 736 . : .  . . .

ISBN 966-506-117-8 (.)

      /   Delphi 3.  
      /,   
   CASE-        .
  ,       /  
Sybase SQL Server, Microsoft SQL Server, Oracle  InterBase.  ,     
  Internet (Web-, Web-,  ActiveForm  .),  API 
Borland Database Engine,   ,     ..

       .

 32.973.2

         .
                      

  ,     ,       ,    

   Sams Corporation.

Authorized translation from the English language edition published by Sams Corporation Copyright  1997

All rights reserved. No part of this book may be reproduced or transmitted in any form or by any means, electronic or mechanical, including
photocopying, recording or by any information storage retrieval system, without permission from the Publisher.
Russian language edition published by Dialektika Computer Publishing Copyright  1997

ISBN 0-672-31024-4 (.)
ISBN 966-506-117-8 (.)

 Sams Corporation, 1997
 ,  "", 1997




     

     1997. 

             
  Borland   Delphi 3.   , 
           ,  
   ,      
  . 
            ,  
    Delphi,      
  Delphi 3, ,     
   ,    
 ActiveX,       
 -,     Internet,  
 Code Insight  .. 
        ,    
  : "      Delphi,   
          SQL, 
   ..?" 
    ".     Delphi 3   /. 
 ,"   . 
    ,     ,     , 
 Delphi,    ,    
 .       ,   
    ,   ,     
  . 

      

      (Danny Thorpe)     Borland   Delphi. 


     

            (Neil Coy), 
         Turbo Pascal. 
 ,   ,     . 
  ,       
  . 
           (Nancy )   - 
(McClure)    .       , 
  ,          
 .     ,      ,  
   ,     .   
,   ,         
-     . 
             
        ,    
       . 
         ,   
 Sams.         
   (Chris Denny),      
Sams. , ,    ,   ,  
 "". ,    ,  
 (Kenneth E. Routen),         
  ,   ,    .   
      ,   ,   
        . , 
     -  ,    
   ,      . 

      

         (Ken Henderson)    
, , ,  ,  -, 
  ,  ...    .     
        /.  
    Delphi        
           ,   
   .    , . ,  , ,   
 .      : khen@compuserve. corn

     

         ,      . 
-,        ,  
    /   Delphi. -, 
 ,     ,  
Delphi,     /. , -, 
     ,      
    .     
   . 

        

         ,   
      , 
    /.      
,      SQL,      
      .  ,   
    Delphi,      ,  
    Delphi.       
    ,    -  
    .      
          Delphi. 
    ,      
  ,        
   /.   ,    
  ,       ,  
  ,        
,     . 

     Delphi 

     Delphi 3      Desktop, Developer  
Client/Server.         
 .     :    
  /,    Client/Server. 
          ,  
,     . Delphi 
  Client/Server       
   SQL,      
.        ,    
  . 

     

          ,  , 
  .      ,   
,         
.  ,     ,   
   ,  . ,    
             
..          Delphi 
 T,     . ,        
,             
 .   ,        
         
.            
    "" ,  ,  ,  
 . ,    ,    
,    ,       . 
     ,   , , ,     
    /    
  /.   ,    
/,     /,   
      . ,  
  ,      , ,   
      /,     
  ,   . 

     9 


      

          "", " ", " 
"  "  ". 
     I. .    ,   
     .   ,  ,   
 SQL,     ,  
      .. 
     II.  .        
    /   Delphi   
    . 
     III.  .   ,    
       .   
    ,  Delphi. 
     IV.   .  ,   
,        /.  
,    ,   -, 
    ,    , 
       ..  ,    
 ,   . 

        

       ,  ,  Delphi     
     , ,   -    
.     : Delphi  ,    
 .   Delphi     , 
  ,           
          ( 
 ,  ,        
 ,     ). ,   
  Delphi,    .    Object Pascal 
 , a Delphi    ?   
   , !            
.      . ,      
    /,      
 Delphi. 

      "" 

           , 
         : 252005, 
-5, / 152, ""   : niarin@dcp.kiev.ua 
     ,           . 

    10  

      Delphi ? 

     1

     -        ,  
 ,    ,     
   ,    .    
    /, CASE-, 
- .      
Java    ,      . 
       ,       
 ,        
  .      
         
 .       
 ,   ,      
 . ,    
/,  ""      
"" ,  Paradox  .. 
         ,  Delphi   
     .     
,           
    . Delphi  
     (RAD  Rapid Application 
Development),        
  .      , 
  Internet        
,    Delphi       
     Windows.  Delphi   
 ,       ,   
 . 
      ,     , Delphi    
  ,        
 . Delphi        , 
    .  , Delphi    
          . Delphi   
 ,    ,     . 
         ,   Delphi   . 
  ,      Delphi,  
      /.  
 ,    ,       
   /   Delphi. 

      Delphi? 

    ,   Delphi    
/ ,    ,    
: "   Delphi?"   ,     
  ,      
/. PowerBuilder, Visual Basic      
       .   
       Delphi? 

    12  I.  

      
         ,     
  ,     .   
  ,    Delphi   
    ,  Visual Basic  PowerBuilder. 
,      Delphi     
    Visual Basic  PowerBuilder,  . 

      ,     .    ,  Delphi  
       
, ,  ,      RAD.   
          
,     .  ,  
PowerBuilder  Visual Basic,      
 .   ,     
,   .   Delphi   
Microsoft,    Powersoft      
 . -,   ""  
"",          .  
   ,    Visual Basic,   PowerScript  
  ,       
   .     
,       . 
          Object Pascal,  
  Delphi,    . Object Pascal   
 ,        , 
      .  
 : Delphi     
   /.  Delphi  Visual Basic 
 PowerBuilder       C++  
 Clipper   DOS.   Delphi   
    /    
    . ,     
   ,   Delphi   . 
     ,    Delphi  " "  
 " ".      
    Pascal  Borland,     
       .   Pascal 
        , 
         
.  Object Pascal,   Delphi,  
 .  ,   Delphi     
 ,    Borland     
 C++.  ,  Delphi,    , 
   C++,    ,     . 
           
 .   ,   ,   , 
   ,       , 
,   ,      .   
 ,    - 
,    ,  ,   
, .   ,      
    ,      DLL   
. ,        ,  
           . 
          Delphi.     
,    Borland    ,  
  ,       Windows,   
  .   Delphi    ,  
      ,   
    .   ,   
       .  
    ,      
 ,   ,     ' 
 Windows,    .   Delphi, 
           
 , ,  ,     DLL, 
 ,    . ,   , 
 Delphi   ,     
,         Windows,  
     .    Delphi 
    Delphi! 

     1.   Delphi ? 13 

             ,  
Delphi      . 
    ,   ,     
Delphi     : 
    Q   ; 
    Q   ,   ; 
    Q  ,   ; 
    Q        ; 
    Q       . 
             . 
 ,     ,       . 

      

            
 Delphi,        
    ?         , 
    Delphi? 
      .      RAD,  
Delphi        
   ,       , 
  Delphi  " ".      
   ActiveX, Delphi      . 
         Delphi,     : 
    Q      Windows; 
    Q        ; 
         VCL  ActiveX; 
    Q   DLL     Windows; 
    Q    ; 
    Q         
,      ,     . 
     ,      ,  
    (),  
  .       
 ,        , 
   .   ,  -  
    ,     , 
        .  
,       , 
    . 
    Q  (inheritance).      
        . 
    Q  (polymorphism).       
         ,   
  ,   . ,  show  
   ,        
,         .  , 
    ,    show     
 ;        
  . 
    Q  (encapsulation).       
 ,  .  ,   
        ( 
).         
   . 

    14  I.  

    Q  .   .  
-        
    ,     
 ,   .    
 ,      
.       
,    ,    . 
    Delphi    ,     
 ,      C++.   
  ,     Pascal  Borland  
 -    
-       Microsoft,   
 Borland.    Delphi    "",   
,      .    
 ,  Borland     
 ,     . 
      Delphi     RAD,  
  ,  ,   ,     
 ,        
 .    , Delphi    
 Turbo Pascal  Borland.    80-   
  Pascal,   ,       
  .  Delphi       
     RAD.   ,   
Visual Basic  PowerBuilder.       
  .       
      . -    
     .   
          
 .        ,  
      .   ,   
 .       
    (     
    !)  ,    
    ,    . 

     

           / 
   (scalability), ..     
,     .  -   
      dBASE,    Sybase  
  .    .  
   Delphi       
,             
.  ,     
,   . 
    Q   ,    ,   
     . 
    Q           . 
    Q           
 Borland Database Engine (BDE),   
     . 
    Q     BDE     /. 
    Q  DataSet   ,   
    ,   BDE. 
    Q        . 
    Q   ODBC. 
     , Delphi         
  /.    ,   
 ,    SQL, Delphi   , 
     ,         
 . 

     1.   Delphi ? 15 

        

        ,     
.       ,   
  . 
     2.  .   ,     
     Delphi    .   
    Delphi        
 . 
     3.  .    ,   
   np   Delphi.     
  Delphi,     . 
     4. .         
       ,    
    Object Pascal. 
     5. SQL   .      
  SQL        SQL   
  ,    .      
    . 
     6.     /.  
          
     Delphi.     , 
    . 
     7.    /.   
        
   .  6  7      
 ,       . 
     8.    /.     
 ,  " ".  814    
       
 /. 
     15. Microsoft SQL Server.    ,  
 .     ,   
   Delphi,     
Microsoft SQL Server.       ,    
   . 
     16. Oracle.      Delphi 
,    Oracle.     Oracle,  
   ,         
    .   Oracle    
   ,        Delphi 
     Oracle. 
     17. InterBase.        
InterBase.     Delphi,   ,   
      InterBase.   
    InterBase      
  Delphi  InterBase. 
     18. Sybase SQL Server.      
     Delphi,   Sybase SQL 
Server.     Delphi     
   Sybase SQL Server,     . 
     19. .      ,  
   .      
      Delphi.  ,   
    ,       
   . 
     20. -    .    21, 
-  ,       
       ,    Delphi. 
     22.    .    
  Delphi    /. 
     23.    .     
        ,   
 Delphi.          
       BDE,   
   /,    
   .      
      Delphi,     . 
     24.    SQL.     
     SQL.   5    
  SQL,    -

    16  I.  

    ,    SQL.  
     ,    
,    .  ,     
    SQL     
  . 
     25.    /.   
     ,    
Delphi    /.     
     ,    ,  
  . 
     26, Borland Database Engine.      
       Borland Database Engine. 
  ,  ,       
 BDE (IDAPI),    ,       
   Delphi. 
     27.    .    
    .       
        ,    
   . 
     28.     Internet.    
 ,     Internet.   
  ,       
 NSAPI  ISAPI,   Web,   
 ActiveForm OCX,        Internet. 
     29.  .       
   ,      Delphi,  
          
 / ,    .  
,     ,    
     InstallShield, 
   Delphi. 
    . Delphi   .   ,  
         Delphi.  
      Delphi  PowerBuilder, Visual 
Basic, C++     Xbase. 

     

        Delphi      
 ,   .  Delphi  
 ,          ,   
      Windows.      
      Delphi   ,  
        , 
     . , Delphi     
  . 
    Q   . 
    Q    . 
    Q    . 
       . 
         . 
    Q       VCL  ActiveX. 
    Q      Windows. 
    Q   . 
    Q      DLL     Windows. 
    Q       . 
    Delphi        
/.       RAD  ,  
PowerBuilder  Visual Basic,  ,   Delphi    
,     .      
 ,   Optima++, Delphi     
 .    ,     
 "  /" Delphi    
     . ,  ,  
   -    Delphi  
-

     1.   Delphi ? 17 

    ,   . , 
      , ,  
Delphi            
  ""   . ,  Microsoft 
 ,      ,   
Delphi,   ,         
  Visual Basic 5   (,  
). ,      ,   . 

    18  I.  

