Marco's Web Center

Menu for Development

Site Menu
Object Pascal Handbook
Delphi Handbooks Collection
Mastering Borland Delphi 2005
(Old) White Papers
(Old)Tools
(Old) Conferences

My Other Sites
Italian Site (www.marcocantu.it)
the delphi search

Spirit of delphi

Advertising
Home My Blog Books Object Pascal Marco

Home: Code Repository: Mastering Delphi 6

Chapter 18 - Project RepProgr

Project Structure

RepProgr.dpr
program RepProgr;

uses
  Forms,
  RepProgF in 'RepProgF.pas' {Form1};

{$R *.RES}

begin
  Application.Initialize;
  Application.CreateForm(TForm1, Form1);
  Application.Run;
end.
RepProgF.pas
unit RepProgF;

interface

uses
  Windows, Messages, SysUtils, Classes, Graphics, Controls,
  Forms, Dialogs, Grids, DBGrids, ComCtrls, StdCtrls, Mask,
  DBCtrls, DBCGrids, Db, DBTables, MdRepPr;

type
  TForm1 = class(TForm)
    DBCtrlGrid1: TDBCtrlGrid;
    DBEdit1: TDBEdit;
    MdDbRepProgress1: TMdDbRepProgress;
    DBGrid1: TDBGrid;
    Table1: TTable;
    DataSource1: TDataSource;
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.DFM}

end.
RepProgF.dfm
object Form1: TForm1
  Left = 200
  Top = 122
  Width = 550
  Height = 417
  Caption = 'RepProgr'
  Color = clBtnFace
  Font.Charset = DEFAULT_CHARSET
  Font.Color = clWindowText
  Font.Height = -11
  Font.Name = 'MS Sans Serif'
  Font.Style = []
  OldCreateOrder = True
  PixelsPerInch = 96
  TextHeight = 13
  object DBCtrlGrid1: TDBCtrlGrid
    Left = 8
    Top = 140
    Width = 520
    Height = 240
    ColCount = 2
    DataSource = DataSource1
    PanelHeight = 80
    PanelWidth = 252
    TabOrder = 0
    RowCount = 3
    object DBEdit1: TDBEdit
      Left = 24
      Top = 16
      Width = 177
      Height = 21
      DataField = 'CustNo'
      DataSource = DataSource1
      TabOrder = 0
    end
    object MdDbRepProgress1: TMdDbRepProgress
      Left = 24
      Top = 48
      Width = 177
      Height = 16
      Min = 0
      Max = 10
      Position = 4
      Step = 2
      TabOrder = 1
      DataField = 'NumTickets'
      DataSource = DataSource1
    end
  end
  object DBGrid1: TDBGrid
    Left = 8
    Top = 8
    Width = 521
    Height = 129
    DataSource = DataSource1
    TabOrder = 1
    TitleFont.Charset = DEFAULT_CHARSET
    TitleFont.Color = clWindowText
    TitleFont.Height = -11
    TitleFont.Name = 'MS Sans Serif'
    TitleFont.Style = []
  end
  object Table1: TTable
    Active = True
    DatabaseName = 'DBDEMOS'
    TableName = 'RESERVAT.DB'
    Left = 24
    Top = 16
  end
  object DataSource1: TDataSource
    DataSet = Table1
    Left = 80
    Top = 16
  end
end