⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 dierj.~pas

📁 库房管理程序,希望能给大家一点启发.这个小程序现在已经用在我们这里的工段,反应良好.
💻 ~PAS
字号:
unit dierj;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, StdCtrls, Buttons, ExtCtrls, jpeg;

type
  TForm2 = class(TForm)
    Image1: TImage;
    Panel2: TPanel;
    BitBtn5: TBitBtn;
    BitBtn1: TBitBtn;
    Panel1: TPanel;
    Panel3: TPanel;
    Panel4: TPanel;
    procedure BitBtn1Click(Sender: TObject);
    procedure BitBtn5Click(Sender: TObject);
    procedure Panel2Click(Sender: TObject);
    procedure Panel4Click(Sender: TObject);
    procedure Panel1Click(Sender: TObject);
    procedure Panel3Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form2: TForm2;

implementation

{$R *.dfm}
  uses denglu,gaimm,rkcx,xxwh,ckjm,wzcx;
procedure TForm2.BitBtn1Click(Sender: TObject);
begin
 denglu.Form1.Close;
 dierj.Form2.Close;

end;

procedure TForm2.BitBtn5Click(Sender: TObject);
begin
 gaimm.Form3.Show;
end;

procedure TForm2.Panel2Click(Sender: TObject);
begin
 // Application.CreateForm(TForm4, Form2);
       // Application.CreateForm(TForm8, Form1);
        rkcx.Form4.ADOQuery3.Close;
         rkcx.Form4.adoquery3.Active:=false;
         rkcx.Form4.adoquery3.Connection:=rkcx.Form4.ADOConnection3;
         rkcx.Form4.adoquery3.SQL.Clear;
         rkcx.Form4.adoquery3.SQL.Add('select * from 工段库房库名 where 工段名称='''+denglu.gdlx+'''');
         rkcx.Form4.adoquery3.Active:=true;
         rkcx.Form4.adoquery3.Open;
           while  not  rkcx.Form4.adoquery3.Eof do
             begin
                rkcx.Form4.ComboBox2.Items.Add( rkcx.Form4.adoquery3.FieldByName('工段库房库名').AsString);
                rkcx.Form4.adoquery3.Next;
             end;

       // xxwh.Form8.adoquery4.Close;


        // ADOQuery4.Close;
       // ComboBox3.Text:='';
         rkcx.Form4.adoquery4.Close;
         rkcx.Form4.adoquery4.Active:=false;
         rkcx.Form4.adoquery4.Connection:=rkcx.Form4.ADOConnection4;
         rkcx.Form4.adoquery4.SQL.Clear;
         rkcx.Form4.adoquery4.SQL.Add('select * from 工段物资位置 where 工段名称='''+denglu.gdlx+'''');
         rkcx.Form4.adoquery4.Active:=true;
         rkcx.Form4.adoquery4.Open;
           while  not  rkcx.Form4.adoquery4.Eof do
             begin
                rkcx.Form4.ComboBox3.Items.Add( rkcx.Form4.adoquery4.FieldByName('工段物资位置').AsString);
                rkcx.Form4.adoquery4.Next;
             end;

   rkcx.Form4.Show;
end;

procedure TForm2.Panel4Click(Sender: TObject);
begin
//Application.CreateForm(TForm4, Form2);
      //  Application.CreateForm(TForm8, Form1);
   xxwh.Form8.ADOQuery2.Close;
        xxwh.Form8.ComboBox2.Text:='';
        xxwh.Form8.adoquery2.Close;
        xxwh.Form8.adoquery2.Active:=false;
        xxwh.Form8.adoquery2.Connection:=xxwh.Form8.ADOConnection2;
        xxwh.Form8.adoquery2.SQL.Clear;
        xxwh.Form8.adoquery2.SQL.Add('select * from 工段领料名单 where 工段名称='''+denglu.gdlx+'''');
        xxwh.Form8.adoquery2.Active:=true;
        xxwh.Form8.adoquery2.Open;
           while  not xxwh.Form8.adoquery2.Eof do
             begin
               xxwh.Form8.ComboBox2.Items.Add(xxwh.Form8.adoquery2.FieldByName('人员姓名').AsString);
               xxwh.Form8.adoquery2.Next;
             end;
        xxwh.Form8.adoquery2.Close;

        //adoquery3.Close;
       // ComboBox3.Text:='';
        xxwh.Form8.adoquery3.Close;
        xxwh.Form8.adoquery3.Active:=false;
        xxwh.Form8.adoquery3.Connection:=xxwh.Form8.ADOConnection3;
        xxwh.Form8.adoquery3.SQL.Clear;
        xxwh.Form8.adoquery3.SQL.Add('select * from 工段发料名单 where 工段名称='''+denglu.gdlx+'''');
        xxwh.Form8.adoquery3.Active:=true;
        xxwh.Form8.adoquery3.Open;
           while  not xxwh.Form8.adoquery3.Eof do
             begin
               xxwh.Form8.ComboBox3.Items.Add(xxwh.Form8.adoquery3.FieldByName('人员名单').AsString);
               xxwh.Form8.adoquery3.Next;
             end;
        xxwh.Form8.adoquery3.Close;


         //adoquery4.Close;
        //ComboBox4.Text:='';

        //showmessage(denglu.gdlx);
        xxwh.Form8.adoquery4.Close;
        xxwh.Form8.adoquery4.Active:=false;
        xxwh.Form8.adoquery4.Connection:=xxwh.Form8.ADOConnection4;
        xxwh.Form8.adoquery4.SQL.Clear;
        xxwh.Form8.adoquery4.SQL.Add('select * from 工段库房库名 where 工段名称='''+denglu.gdlx+'''');
        xxwh.Form8.adoquery4.Active:=true;
        xxwh.Form8.adoquery4.Open;
           while  not xxwh.Form8.adoquery4.Eof do
             begin
               xxwh.Form8.ComboBox4.Items.Add(xxwh.Form8.adoquery4.FieldByName('工段库房库名').AsString);
              xxwh.Form8.adoquery4.Next;
             end;
        xxwh.Form8.adoquery4.Close;

        // adoquery5.Close;
        //ComboBox5.Text:='';
        xxwh.Form8.adoquery5.Close;
        xxwh.Form8.adoquery5.Active:=false;
        xxwh.Form8.adoquery5.Connection:=xxwh.Form8.ADOConnection5;
        xxwh.Form8.adoquery3.SQL.Clear;
        xxwh.Form8.adoquery5.SQL.Add('select * from 工段物资位置 where 工段名称='''+denglu.gdlx+'''');
        xxwh.Form8.adoquery5.Active:=true;
        xxwh.Form8.adoquery5.Open;
           while  not xxwh.Form8.adoquery5.Eof do
             begin
               xxwh.Form8.ComboBox5.Items.Add(xxwh.Form8.adoquery5.FieldByName('工段物资位置').AsString);
               xxwh.Form8.adoquery5.Next;
             end;
        xxwh.Form8.adoquery5.Close;
   xxwh.Form8.Show;
end;

procedure TForm2.Panel1Click(Sender: TObject);
begin
    xxwh.Form8.ADOQuery2.Close;
        xxwh.Form8.ComboBox2.Text:='';
        xxwh.Form8.adoquery2.Close;
        xxwh.Form8.adoquery2.Active:=false;
        xxwh.Form8.adoquery2.Connection:=xxwh.Form8.ADOConnection2;
        xxwh.Form8.adoquery2.SQL.Clear;
        xxwh.Form8.adoquery2.SQL.Add('select * from 工段领料名单 where 工段名称='''+denglu.gdlx+'''');
        xxwh.Form8.adoquery2.Active:=true;
        xxwh.Form8.adoquery2.Open;
           while  not xxwh.Form8.adoquery2.Eof do
             begin
               ckjm.Form5.ComboBox2.Items.Add(xxwh.Form8.adoquery2.FieldByName('人员姓名').AsString);
               xxwh.Form8.adoquery2.Next;
             end;
        xxwh.Form8.adoquery2.Close;

        //adoquery3.Close;
       // ComboBox3.Text:='';
        xxwh.Form8.adoquery3.Close;
        xxwh.Form8.adoquery3.Active:=false;
        xxwh.Form8.adoquery3.Connection:=xxwh.Form8.ADOConnection3;
        xxwh.Form8.adoquery3.SQL.Clear;
        xxwh.Form8.adoquery3.SQL.Add('select * from 工段发料名单 where 工段名称='''+denglu.gdlx+'''');
        xxwh.Form8.adoquery3.Active:=true;
        xxwh.Form8.adoquery3.Open;
           while  not xxwh.Form8.adoquery3.Eof do
             begin
               ckjm.Form5.ComboBox1.Items.Add(xxwh.Form8.adoquery3.FieldByName('人员名单').AsString);
               xxwh.Form8.adoquery3.Next;
             end;
        xxwh.Form8.adoquery3.Close;
        ckjm.Form5.Show;

end;

procedure TForm2.Panel3Click(Sender: TObject);
begin
      wzcx.Form10.Show;
end;

end.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -