frminput.frm
上传用户:laihaixin
上传日期:2013-01-26
资源大小:1169k
文件大小:33k
源码类别:

医药行业

开发平台:

Visual Basic

  1. VERSION 5.00
  2. Object = "{67397AA1-7FB1-11D0-B148-00A0C922E820}#6.0#0"; "MSADODC.OCX"
  3. Begin VB.Form frminput 
  4.    BackColor       =   &H00404040&
  5.    BorderStyle     =   3  'Fixed Dialog
  6.    Caption         =   "库存登记"
  7.    ClientHeight    =   4545
  8.    ClientLeft      =   45
  9.    ClientTop       =   330
  10.    ClientWidth     =   8610
  11.    Icon            =   "frminput.frx":0000
  12.    LinkTopic       =   "Form1"
  13.    MaxButton       =   0   'False
  14.    MDIChild        =   -1  'True
  15.    MinButton       =   0   'False
  16.    Picture         =   "frminput.frx":030A
  17.    ScaleHeight     =   4545
  18.    ScaleWidth      =   8610
  19.    ShowInTaskbar   =   0   'False
  20.    Begin VB.ComboBox Combo2 
  21.       Height          =   300
  22.       ItemData        =   "frminput.frx":59F9
  23.       Left            =   1200
  24.       List            =   "frminput.frx":5A06
  25.       TabIndex        =   48
  26.       Top             =   4080
  27.       Width           =   1335
  28.    End
  29.    Begin MSAdodcLib.Adodc Adodc2 
  30.       Height          =   330
  31.       Left            =   6000
  32.       Top             =   75
  33.       Visible         =   0   'False
  34.       Width           =   1200
  35.       _ExtentX        =   2117
  36.       _ExtentY        =   582
  37.       ConnectMode     =   0
  38.       CursorLocation  =   3
  39.       IsolationLevel  =   -1
  40.       ConnectionTimeout=   15
  41.       CommandTimeout  =   30
  42.       CursorType      =   3
  43.       LockType        =   3
  44.       CommandType     =   8
  45.       CursorOptions   =   0
  46.       CacheSize       =   50
  47.       MaxRecords      =   0
  48.       BOFAction       =   0
  49.       EOFAction       =   0
  50.       ConnectStringType=   1
  51.       Appearance      =   1
  52.       BackColor       =   -2147483643
  53.       ForeColor       =   -2147483640
  54.       Orientation     =   0
  55.       Enabled         =   -1
  56.       Connect         =   ""
  57.       OLEDBString     =   ""
  58.       OLEDBFile       =   ""
  59.       DataSourceName  =   ""
  60.       OtherAttributes =   ""
  61.       UserName        =   ""
  62.       Password        =   ""
  63.       RecordSource    =   ""
  64.       Caption         =   "Adodc2"
  65.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  66.          Name            =   "宋体"
  67.          Size            =   9
  68.          Charset         =   134
  69.          Weight          =   400
  70.          Underline       =   0   'False
  71.          Italic          =   0   'False
  72.          Strikethrough   =   0   'False
  73.       EndProperty
  74.       _Version        =   393216
  75.    End
  76.    Begin MSAdodcLib.Adodc Adodc3 
  77.       Height          =   330
  78.       Left            =   7320
  79.       Top             =   75
  80.       Visible         =   0   'False
  81.       Width           =   1215
  82.       _ExtentX        =   2143
  83.       _ExtentY        =   582
  84.       ConnectMode     =   0
  85.       CursorLocation  =   3
  86.       IsolationLevel  =   -1
  87.       ConnectionTimeout=   15
  88.       CommandTimeout  =   30
  89.       CursorType      =   3
  90.       LockType        =   3
  91.       CommandType     =   8
  92.       CursorOptions   =   0
  93.       CacheSize       =   50
  94.       MaxRecords      =   0
  95.       BOFAction       =   0
  96.       EOFAction       =   0
  97.       ConnectStringType=   1
  98.       Appearance      =   1
  99.       BackColor       =   -2147483643
  100.       ForeColor       =   -2147483640
  101.       Orientation     =   0
  102.       Enabled         =   -1
  103.       Connect         =   ""
  104.       OLEDBString     =   ""
  105.       OLEDBFile       =   ""
  106.       DataSourceName  =   ""
  107.       OtherAttributes =   ""
  108.       UserName        =   ""
  109.       Password        =   ""
  110.       RecordSource    =   ""
  111.       Caption         =   "Adodc3"
  112.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  113.          Name            =   "宋体"
  114.          Size            =   9
  115.          Charset         =   134
  116.          Weight          =   400
  117.          Underline       =   0   'False
  118.          Italic          =   0   'False
  119.          Strikethrough   =   0   'False
  120.       EndProperty
  121.       _Version        =   393216
  122.    End
  123.    Begin MSAdodcLib.Adodc Adodc1 
  124.       Height          =   330
  125.       Left            =   4680
  126.       Top             =   75
  127.       Visible         =   0   'False
  128.       Width           =   1200
  129.       _ExtentX        =   2117
  130.       _ExtentY        =   582
  131.       ConnectMode     =   0
  132.       CursorLocation  =   3
  133.       IsolationLevel  =   -1
  134.       ConnectionTimeout=   15
  135.       CommandTimeout  =   30
  136.       CursorType      =   3
  137.       LockType        =   3
  138.       CommandType     =   8
  139.       CursorOptions   =   0
  140.       CacheSize       =   50
  141.       MaxRecords      =   0
  142.       BOFAction       =   0
  143.       EOFAction       =   0
  144.       ConnectStringType=   1
  145.       Appearance      =   1
  146.       BackColor       =   -2147483643
  147.       ForeColor       =   -2147483640
  148.       Orientation     =   0
  149.       Enabled         =   -1
  150.       Connect         =   ""
  151.       OLEDBString     =   ""
  152.       OLEDBFile       =   ""
  153.       DataSourceName  =   ""
  154.       OtherAttributes =   ""
  155.       UserName        =   ""
  156.       Password        =   ""
  157.       RecordSource    =   ""
  158.       Caption         =   "Adodc1"
  159.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  160.          Name            =   "宋体"
  161.          Size            =   9
  162.          Charset         =   134
  163.          Weight          =   400
  164.          Underline       =   0   'False
  165.          Italic          =   0   'False
  166.          Strikethrough   =   0   'False
  167.       EndProperty
  168.       _Version        =   393216
  169.    End
  170.    Begin VB.CommandButton Command4 
  171.       Caption         =   "关闭&(Q)"
  172.       Height          =   350
  173.       Left            =   7335
  174.       TabIndex        =   45
  175.       Top             =   4080
  176.       Width           =   1200
  177.    End
  178.    Begin VB.CommandButton Command3 
  179.       BackColor       =   &H00404040&
  180.       Caption         =   "查看代码&(U)"
  181.       Height          =   350
  182.       Left            =   6000
  183.       TabIndex        =   44
  184.       Top             =   4080
  185.       Width           =   1200
  186.    End
  187.    Begin VB.CommandButton Command2 
  188.       BackColor       =   &H00C0C0C0&
  189.       Caption         =   "增加库存量&(S)"
  190.       Height          =   350
  191.       Left            =   4380
  192.       MaskColor       =   &H00808080&
  193.       TabIndex        =   43
  194.       Top             =   4080
  195.       Width           =   1500
  196.    End
  197.    Begin VB.CommandButton Command1 
  198.       Caption         =   "添加新品种&(A)"
  199.       Height          =   350
  200.       Left            =   2760
  201.       TabIndex        =   42
  202.       Top             =   4080
  203.       Width           =   1500
  204.    End
  205.    Begin VB.PictureBox Picture1 
  206.       BackColor       =   &H00404040&
  207.       Height          =   3495
  208.       Left            =   120
  209.       Picture         =   "frminput.frx":5A2E
  210.       ScaleHeight     =   3435
  211.       ScaleWidth      =   8295
  212.       TabIndex        =   19
  213.       Top             =   480
  214.       Width           =   8355
  215.       Begin VB.TextBox Text18 
  216.          ForeColor       =   &H000000FF&
  217.          Height          =   270
  218.          Left            =   3960
  219.          TabIndex        =   1
  220.          Top             =   170
  221.          Width           =   1200
  222.       End
  223.       Begin VB.TextBox Text17 
  224.          BackColor       =   &H00FFFFFF&
  225.          ForeColor       =   &H00FF0000&
  226.          Height          =   1410
  227.          Left            =   1320
  228.          TabIndex        =   18
  229.          Top             =   1880
  230.          Width           =   6495
  231.       End
  232.       Begin VB.TextBox Text16 
  233.          Alignment       =   1  'Right Justify
  234.          BackColor       =   &H00FFFFFF&
  235.          ForeColor       =   &H000000FF&
  236.          Height          =   270
  237.          Left            =   7200
  238.          TabIndex        =   17
  239.          Top             =   1540
  240.          Width           =   375
  241.       End
  242.       Begin VB.TextBox Text15 
  243.          Alignment       =   1  'Right Justify
  244.          BackColor       =   &H00FFFFFF&
  245.          ForeColor       =   &H000000FF&
  246.          Height          =   270
  247.          Left            =   6480
  248.          TabIndex        =   16
  249.          Top             =   1540
  250.          Width           =   375
  251.       End
  252.       Begin VB.TextBox Text14 
  253.          Alignment       =   1  'Right Justify
  254.          BackColor       =   &H00FFFFFF&
  255.          ForeColor       =   &H000000FF&
  256.          Height          =   270
  257.          Left            =   5520
  258.          TabIndex        =   15
  259.          Top             =   1540
  260.          Width           =   600
  261.       End
  262.       Begin VB.TextBox Text13 
  263.          Alignment       =   1  'Right Justify
  264.          BackColor       =   &H00FFFFFF&
  265.          ForeColor       =   &H000000FF&
  266.          Height          =   270
  267.          Left            =   3000
  268.          TabIndex        =   14
  269.          Top             =   1540
  270.          Width           =   375
  271.       End
  272.       Begin VB.TextBox Text12 
  273.          Alignment       =   1  'Right Justify
  274.          BackColor       =   &H00FFFFFF&
  275.          ForeColor       =   &H000000FF&
  276.          Height          =   270
  277.          Left            =   2280
  278.          TabIndex        =   13
  279.          Top             =   1540
  280.          Width           =   375
  281.       End
  282.       Begin VB.TextBox Text11 
  283.          Alignment       =   1  'Right Justify
  284.          BackColor       =   &H00FFFFFF&
  285.          ForeColor       =   &H000000FF&
  286.          Height          =   270
  287.          Left            =   1320
  288.          TabIndex        =   12
  289.          Top             =   1540
  290.          Width           =   600
  291.       End
  292.       Begin VB.TextBox Text10 
  293.          Alignment       =   1  'Right Justify
  294.          BackColor       =   &H00FFFFFF&
  295.          ForeColor       =   &H000000FF&
  296.          Height          =   270
  297.          Left            =   7200
  298.          TabIndex        =   11
  299.          Top             =   1220
  300.          Width           =   375
  301.       End
  302.       Begin VB.TextBox Text9 
  303.          Alignment       =   1  'Right Justify
  304.          BackColor       =   &H00FFFFFF&
  305.          ForeColor       =   &H000000FF&
  306.          Height          =   270
  307.          Left            =   6480
  308.          TabIndex        =   10
  309.          Top             =   1220
  310.          Width           =   375
  311.       End
  312.       Begin VB.TextBox Text8 
  313.          Alignment       =   1  'Right Justify
  314.          BackColor       =   &H00FFFFFF&
  315.          ForeColor       =   &H000000FF&
  316.          Height          =   270
  317.          Left            =   5520
  318.          TabIndex        =   9
  319.          Top             =   1220
  320.          Width           =   600
  321.       End
  322.       Begin VB.TextBox Text7 
  323.          Alignment       =   1  'Right Justify
  324.          BackColor       =   &H00FFFFFF&
  325.          ForeColor       =   &H000000FF&
  326.          Height          =   270
  327.          Left            =   1320
  328.          TabIndex        =   8
  329.          Top             =   1220
  330.          Width           =   1200
  331.       End
  332.       Begin VB.TextBox Text6 
  333.          BackColor       =   &H00FFFFFF&
  334.          ForeColor       =   &H000000FF&
  335.          Height          =   270
  336.          Left            =   3960
  337.          TabIndex        =   7
  338.          Top             =   880
  339.          Width           =   3855
  340.       End
  341.       Begin VB.TextBox Text5 
  342.          Alignment       =   1  'Right Justify
  343.          BackColor       =   &H00FFFFFF&
  344.          ForeColor       =   &H000000FF&
  345.          Height          =   270
  346.          Left            =   1320
  347.          TabIndex        =   6
  348.          Top             =   880
  349.          Width           =   1200
  350.       End
  351.       Begin VB.TextBox Text4 
  352.          Alignment       =   1  'Right Justify
  353.          BackColor       =   &H00FFFFFF&
  354.          ForeColor       =   &H000000FF&
  355.          Height          =   270
  356.          Left            =   6600
  357.          TabIndex        =   5
  358.          Top             =   520
  359.          Width           =   1200
  360.       End
  361.       Begin VB.TextBox Text3 
  362.          Alignment       =   1  'Right Justify
  363.          BackColor       =   &H00FFFFFF&
  364.          ForeColor       =   &H000000FF&
  365.          Height          =   270
  366.          Left            =   3960
  367.          TabIndex        =   4
  368.          Top             =   520
  369.          Width           =   1200
  370.       End
  371.       Begin VB.ComboBox Combo1 
  372.          BackColor       =   &H00FFFFFF&
  373.          ForeColor       =   &H000000FF&
  374.          Height          =   300
  375.          ItemData        =   "frminput.frx":B11D
  376.          Left            =   1320
  377.          List            =   "frminput.frx":B13C
  378.          TabIndex        =   3
  379.          Top             =   520
  380.          Width           =   1200
  381.       End
  382.       Begin VB.TextBox Text2 
  383.          Alignment       =   1  'Right Justify
  384.          BackColor       =   &H00FFFFFF&
  385.          ForeColor       =   &H000000FF&
  386.          Height          =   270
  387.          Left            =   6600
  388.          TabIndex        =   2
  389.          Top             =   170
  390.          Width           =   1200
  391.       End
  392.       Begin VB.TextBox Text1 
  393.          Alignment       =   1  'Right Justify
  394.          BackColor       =   &H00FFFFFF&
  395.          BeginProperty DataFormat 
  396.             Type            =   0
  397.             Format          =   "00000"
  398.             HaveTrueFalseNull=   0
  399.             FirstDayOfWeek  =   0
  400.             FirstWeekOfYear =   0
  401.             LCID            =   2052
  402.             SubFormatType   =   0
  403.          EndProperty
  404.          ForeColor       =   &H000000FF&
  405.          Height          =   270
  406.          Left            =   1320
  407.          MaxLength       =   10
  408.          TabIndex        =   0
  409.          Top             =   170
  410.          Width           =   1200
  411.       End
  412.       Begin VB.Label Label22 
  413.          AutoSize        =   -1  'True
  414.          BackColor       =   &H00404040&
  415.          BackStyle       =   0  'Transparent
  416.          Caption         =   "日"
  417.          ForeColor       =   &H00000000&
  418.          Height          =   180
  419.          Left            =   7650
  420.          TabIndex        =   41
  421.          Top             =   1605
  422.          Width           =   180
  423.       End
  424.       Begin VB.Label Label21 
  425.          AutoSize        =   -1  'True
  426.          BackColor       =   &H00404040&
  427.          BackStyle       =   0  'Transparent
  428.          Caption         =   "月"
  429.          ForeColor       =   &H00000000&
  430.          Height          =   180
  431.          Left            =   6940
  432.          TabIndex        =   40
  433.          Top             =   1605
  434.          Width           =   180
  435.       End
  436.       Begin VB.Label Label20 
  437.          AutoSize        =   -1  'True
  438.          BackColor       =   &H00404040&
  439.          BackStyle       =   0  'Transparent
  440.          Caption         =   "年"
  441.          ForeColor       =   &H00000000&
  442.          Height          =   180
  443.          Left            =   6220
  444.          TabIndex        =   39
  445.          Top             =   1605
  446.          Width           =   180
  447.       End
  448.       Begin VB.Label Label19 
  449.          AutoSize        =   -1  'True
  450.          BackColor       =   &H00404040&
  451.          BackStyle       =   0  'Transparent
  452.          Caption         =   "日"
  453.          ForeColor       =   &H00000000&
  454.          Height          =   180
  455.          Left            =   7650
  456.          TabIndex        =   38
  457.          Top             =   1260
  458.          Width           =   180
  459.       End
  460.       Begin VB.Label Label18 
  461.          AutoSize        =   -1  'True
  462.          BackColor       =   &H00404040&
  463.          BackStyle       =   0  'Transparent
  464.          Caption         =   "月"
  465.          ForeColor       =   &H00000000&
  466.          Height          =   180
  467.          Left            =   6940
  468.          TabIndex        =   37
  469.          Top             =   1260
  470.          Width           =   180
  471.       End
  472.       Begin VB.Label Label17 
  473.          AutoSize        =   -1  'True
  474.          BackColor       =   &H00404040&
  475.          BackStyle       =   0  'Transparent
  476.          Caption         =   "年"
  477.          ForeColor       =   &H00000000&
  478.          Height          =   180
  479.          Left            =   6220
  480.          TabIndex        =   36
  481.          Top             =   1260
  482.          Width           =   180
  483.       End
  484.       Begin VB.Label Label16 
  485.          AutoSize        =   -1  'True
  486.          BackColor       =   &H00404040&
  487.          BackStyle       =   0  'Transparent
  488.          Caption         =   "日"
  489.          ForeColor       =   &H00000000&
  490.          Height          =   180
  491.          Left            =   3400
  492.          TabIndex        =   35
  493.          Top             =   1600
  494.          Width           =   180
  495.       End
  496.       Begin VB.Label Label15 
  497.          AutoSize        =   -1  'True
  498.          BackColor       =   &H00404040&
  499.          BackStyle       =   0  'Transparent
  500.          Caption         =   "月"
  501.          ForeColor       =   &H00000000&
  502.          Height          =   180
  503.          Left            =   2760
  504.          TabIndex        =   34
  505.          Top             =   1600
  506.          Width           =   180
  507.       End
  508.       Begin VB.Label Label14 
  509.          AutoSize        =   -1  'True
  510.          BackColor       =   &H00404040&
  511.          BackStyle       =   0  'Transparent
  512.          Caption         =   "年"
  513.          ForeColor       =   &H00000000&
  514.          Height          =   180
  515.          Left            =   2020
  516.          TabIndex        =   33
  517.          Top             =   1600
  518.          Width           =   180
  519.       End
  520.       Begin VB.Label Label13 
  521.          AutoSize        =   -1  'True
  522.          BackColor       =   &H00404040&
  523.          BackStyle       =   0  'Transparent
  524.          Caption         =   "备    注"
  525.          ForeColor       =   &H00000000&
  526.          Height          =   180
  527.          Left            =   480
  528.          TabIndex        =   32
  529.          Top             =   2400
  530.          Width           =   720
  531.       End
  532.       Begin VB.Label Label12 
  533.          AutoSize        =   -1  'True
  534.          BackColor       =   &H00404040&
  535.          BackStyle       =   0  'Transparent
  536.          Caption         =   "失 效 期"
  537.          ForeColor       =   &H00000000&
  538.          Height          =   180
  539.          Left            =   4680
  540.          TabIndex        =   31
  541.          Top             =   1605
  542.          Width           =   720
  543.       End
  544.       Begin VB.Label Label11 
  545.          AutoSize        =   -1  'True
  546.          BackColor       =   &H00404040&
  547.          BackStyle       =   0  'Transparent
  548.          Caption         =   "出厂日期"
  549.          ForeColor       =   &H00000000&
  550.          Height          =   180
  551.          Left            =   480
  552.          TabIndex        =   30
  553.          Top             =   1600
  554.          Width           =   720
  555.       End
  556.       Begin VB.Label Label10 
  557.          AutoSize        =   -1  'True
  558.          BackColor       =   &H00404040&
  559.          BackStyle       =   0  'Transparent
  560.          Caption         =   "采购日期"
  561.          ForeColor       =   &H00000000&
  562.          Height          =   180
  563.          Left            =   4680
  564.          TabIndex        =   29
  565.          Top             =   1260
  566.          Width           =   720
  567.       End
  568.       Begin VB.Label Label9 
  569.          AutoSize        =   -1  'True
  570.          BackColor       =   &H00404040&
  571.          BackStyle       =   0  'Transparent
  572.          Caption         =   "批    号"
  573.          ForeColor       =   &H00000000&
  574.          Height          =   180
  575.          Left            =   480
  576.          TabIndex        =   28
  577.          Top             =   1260
  578.          Width           =   720
  579.       End
  580.       Begin VB.Label Label8 
  581.          AutoSize        =   -1  'True
  582.          BackColor       =   &H00404040&
  583.          BackStyle       =   0  'Transparent
  584.          Caption         =   "产    地"
  585.          ForeColor       =   &H00000000&
  586.          Height          =   180
  587.          Left            =   3120
  588.          TabIndex        =   27
  589.          Top             =   915
  590.          Width           =   720
  591.       End
  592.       Begin VB.Label Label7 
  593.          AutoSize        =   -1  'True
  594.          BackColor       =   &H00404040&
  595.          BackStyle       =   0  'Transparent
  596.          Caption         =   "零售价格"
  597.          ForeColor       =   &H00000000&
  598.          Height          =   180
  599.          Left            =   480
  600.          TabIndex        =   26
  601.          Top             =   920
  602.          Width           =   720
  603.       End
  604.       Begin VB.Label Label6 
  605.          AutoSize        =   -1  'True
  606.          BackColor       =   &H00404040&
  607.          BackStyle       =   0  'Transparent
  608.          Caption         =   "进货价格"
  609.          ForeColor       =   &H00000000&
  610.          Height          =   180
  611.          Left            =   5760
  612.          TabIndex        =   25
  613.          Top             =   585
  614.          Width           =   720
  615.       End
  616.       Begin VB.Label Label5 
  617.          AutoSize        =   -1  'True
  618.          BackColor       =   &H00404040&
  619.          BackStyle       =   0  'Transparent
  620.          Caption         =   "数    量"
  621.          ForeColor       =   &H00000000&
  622.          Height          =   180
  623.          Left            =   3120
  624.          TabIndex        =   24
  625.          Top             =   585
  626.          Width           =   720
  627.       End
  628.       Begin VB.Label Label4 
  629.          AutoSize        =   -1  'True
  630.          BackColor       =   &H00404040&
  631.          BackStyle       =   0  'Transparent
  632.          Caption         =   "单    位"
  633.          ForeColor       =   &H00000000&
  634.          Height          =   180
  635.          Left            =   480
  636.          TabIndex        =   23
  637.          Top             =   580
  638.          Width           =   720
  639.       End
  640.       Begin VB.Label Label3 
  641.          AutoSize        =   -1  'True
  642.          BackColor       =   &H00404040&
  643.          BackStyle       =   0  'Transparent
  644.          Caption         =   "规    格"
  645.          ForeColor       =   &H00000000&
  646.          Height          =   180
  647.          Left            =   5760
  648.          TabIndex        =   22
  649.          Top             =   240
  650.          Width           =   720
  651.       End
  652.       Begin VB.Label Label2 
  653.          AutoSize        =   -1  'True
  654.          BackColor       =   &H00404040&
  655.          BackStyle       =   0  'Transparent
  656.          Caption         =   "名    称"
  657.          ForeColor       =   &H00000000&
  658.          Height          =   180
  659.          Left            =   3120
  660.          TabIndex        =   21
  661.          Top             =   240
  662.          Width           =   720
  663.       End
  664.       Begin VB.Label Label1 
  665.          AutoSize        =   -1  'True
  666.          BackColor       =   &H00404040&
  667.          BackStyle       =   0  'Transparent
  668.          Caption         =   "编    号"
  669.          ForeColor       =   &H00000000&
  670.          Height          =   180
  671.          Left            =   480
  672.          TabIndex        =   20
  673.          Top             =   240
  674.          Width           =   720
  675.       End
  676.    End
  677.    Begin VB.Label Label25 
  678.       AutoSize        =   -1  'True
  679.       BackStyle       =   0  'Transparent
  680.       Caption         =   "选择数据库"
  681.       Height          =   180
  682.       Left            =   240
  683.       TabIndex        =   49
  684.       Top             =   4140
  685.       Width           =   900
  686.    End
  687.    Begin VB.Label Label24 
  688.       AutoSize        =   -1  'True
  689.       BackStyle       =   0  'Transparent
  690.       Caption         =   "动态提示:"
  691.       ForeColor       =   &H00000000&
  692.       Height          =   180
  693.       Left            =   360
  694.       TabIndex        =   47
  695.       Top             =   120
  696.       Width           =   900
  697.    End
  698.    Begin VB.Label Label23 
  699.       AutoSize        =   -1  'True
  700.       BackStyle       =   0  'Transparent
  701.       ForeColor       =   &H00000000&
  702.       Height          =   180
  703.       Left            =   1245
  704.       TabIndex        =   46
  705.       Top             =   120
  706.       Width           =   90
  707.    End
  708. End
  709. Attribute VB_Name = "frminput"
  710. Attribute VB_GlobalNameSpace = False
  711. Attribute VB_Creatable = False
  712. Attribute VB_PredeclaredId = True
  713. Attribute VB_Exposed = False
  714. Public Sub Guolu()
  715. With Adodc1
  716. .RecordSource = "select * from " & frmmain.datas & " where 失效标记=false"
  717. .Refresh
  718. For i = 0 To .Recordset.RecordCount
  719. If Not .Recordset.EOF Then
  720.     If .Recordset.Fields("失效期") <= Date Then
  721.         .Recordset.Fields("失效标记") = True
  722.         .Recordset.Update
  723.     Else
  724.         .Recordset.Fields("失效标记") = False
  725.         .Recordset.Update
  726.     End If
  727. .Recordset.MoveNext
  728. End If
  729. Next
  730. End With
  731. End Sub
  732. Private Sub combo2_Change()
  733. If Combo2.Text <> "西药中成药库" And Combo2.Text <> "中草药库" And Combo2.Text <> "器械材料库" Then
  734. Text1.Enabled = False
  735. Text18.Enabled = False
  736. End If
  737. End Sub
  738. Private Sub Combo2_Click()
  739. Select Case Combo2.Text
  740. Case "西药中成药库"
  741.     frmmain.datas = "kcyp"
  742.     frminput.Caption = "西药和中成药入库登记"
  743.     frmmain.kcode = "ypcode"
  744.     Call Guolu
  745.     Text1.Enabled = True
  746.     Text18.Enabled = True
  747. Case "中草药库"
  748.     frmmain.datas = "caoyao"
  749.     frminput.Caption = "中草药入库登记"
  750.     frmmain.kcode = "cycode"
  751.     Call Guolu
  752.     Text1.Enabled = True
  753.     Text18.Enabled = True
  754. Case "器械材料库"
  755.     frmmain.datas = "qixie"
  756.     frminput.Caption = "医疗器械和材料入库登记"
  757.     frmmain.kcode = "qxcode"
  758.     Call Guolu
  759.     Text1.Enabled = True
  760.     Text18.Enabled = True
  761. Case Else
  762.     Text1.Enabled = False
  763.     Text18.Enabled = False
  764.     frminput.Caption = "库存登记"
  765. End Select
  766. End Sub
  767. Private Sub Command1_Click()
  768. Dim rq1 As String
  769. Dim rq2 As String
  770. Dim rq3 As String
  771. On Error GoTo err1
  772. With Adodc1
  773. .RecordSource = "select * from " & frmmain.datas & " order by ID"
  774. .Refresh
  775. .Recordset.AddNew
  776. .Recordset.Fields("编号") = Text1.Text
  777. .Recordset.Fields("名称") = Text18.Text
  778. .Recordset.Fields("规格") = Text2.Text
  779. .Recordset.Fields("单位") = Combo1.Text
  780. .Recordset.Fields("数量") = Text3.Text
  781. .Recordset.Fields("进价") = Text4.Text
  782. .Recordset.Fields("进价合计") = (Text3.Text) * (Text4.Text)
  783. .Recordset.Fields("零售价") = Text5.Text
  784. .Recordset.Fields("零售合计") = (Text3.Text) * (Text5.Text)
  785. .Recordset.Fields("产地") = Text6.Text
  786. .Recordset.Fields("差额") = (.Recordset.Fields("零售合计")) - (.Recordset.Fields("进价合计"))
  787. .Recordset.Fields("批号") = Text7.Text
  788. rq1 = Text8.Text & "-" & Text9.Text & "-" & Text10.Text
  789. .Recordset.Fields("采购日期") = CDate(rq1)
  790. rq2 = Text11.Text & "-" & Text12.Text & "-" & Text13.Text
  791. .Recordset.Fields("出厂日期") = CDate(rq2)
  792. rq3 = Text14.Text & "-" & Text15.Text & "-" & Text16.Text
  793. .Recordset.Fields("失效期") = CDate(rq3)
  794. .Recordset.Fields("备注") = Text17.Text
  795. .Recordset.UpdateBatch
  796. Command1.Enabled = False
  797. Text1.Enabled = True
  798. Text18.Enabled = True
  799. Label23.Caption = ""
  800. End With
  801. Exit Sub
  802. err1:
  803. MsgBox "登记项目填写不全或数据类型不匹配!"
  804. End Sub
  805. Private Sub Command2_Click()
  806. '库存过期药品必须清理后才能入库
  807. Dim rq1 As String
  808. Dim rq2 As String
  809. Dim rq3 As String
  810. On Error GoTo err2
  811. With Adodc1
  812. .RecordSource = "select * from " & frmmain.datas & " where 编号='" & Text1.Text & "'"
  813. .Refresh
  814. If .Recordset.Fields("失效标记") = False Then
  815.     If .Recordset.AbsolutePosition <> adPosUnknown Then
  816.     .Recordset.Fields("规格") = Text2.Text
  817.     .Recordset.Fields("单位") = Combo1.Text
  818.     .Recordset.Fields("数量") = Text3.Text
  819.     .Recordset.Fields("进价") = Text4.Text
  820.     .Recordset.Fields("进价合计") = (Text3.Text) * (Text4.Text)
  821.     .Recordset.Fields("零售价") = Text5.Text
  822.     .Recordset.Fields("零售合计") = (Text3.Text) * (Text5.Text)
  823.     .Recordset.Fields("产地") = Text6.Text
  824.     .Recordset.Fields("批号") = Text7.Text
  825.     .Recordset.Fields("差额") = (.Recordset.Fields("零售合计")) - (.Recordset.Fields("进价合计"))
  826.     rq1 = Text8.Text & "-" & Text9.Text & "-" & Text10.Text
  827.     .Recordset.Fields("采购日期") = CDate(rq1)
  828.     rq2 = Text11.Text & "-" & Text12.Text & "-" & Text13.Text
  829.     .Recordset.Fields("出厂日期") = CDate(rq2)
  830.     rq3 = Text14.Text & "-" & Text15.Text & "-" & Text16.Text
  831.     .Recordset.Fields("失效期") = CDate(rq3)
  832.     .Recordset.Fields("备注") = Text17.Text
  833.     .Recordset.UpdateBatch
  834.     End If
  835.     Command2.Enabled = False
  836.     Text1.Enabled = True
  837.     Text18.Enabled = True
  838.     Label23.Caption = ""
  839. Else
  840.     MsgBox "该库存药品已经失效,须清理后才能入库!"
  841. End If
  842. End With
  843. Exit Sub
  844. err2:
  845. MsgBox "登记项目填写不全或数据类型不匹配!"
  846. End Sub
  847. Private Sub Command3_Click()
  848. frmcode.Show
  849. End Sub
  850. Private Sub Command4_Click()
  851. Unload Me
  852. End Sub
  853. Private Sub Form_Load()
  854. On Error GoTo err4
  855. frminput.Top = (frmmain.Height - frminput.Height) / 2 - 500
  856. frminput.Left = (frmmain.Width - frminput.Width) / 2
  857. Adodc1.ConnectionString = frmlogin.conn
  858. Adodc2.ConnectionString = frmlogin.conn
  859. Adodc3.ConnectionString = frmlogin.conn
  860. Command1.Enabled = False
  861. Command2.Enabled = False
  862. Text2.Locked = True
  863. Text1.Enabled = False
  864. Text18.Enabled = False
  865. Text8.Text = "2000"
  866. Text9.Text = "01"
  867. Text10.Text = "01"
  868. Text11.Text = "2000"
  869. Text12.Text = "01"
  870. Text13.Text = "01"
  871. Text14.Text = "2000"
  872. Text15.Text = "01"
  873. Text16.Text = "01"
  874. Text17.Text = "请填写备注"
  875. Exit Sub
  876. err4:
  877. MsgBox "远程服务器连接失败!"
  878. End Sub
  879. Private Sub Text1_Change()
  880. On Error GoTo err3
  881. With Adodc2
  882. .RecordSource = "select * from " & frmmain.kcode & " where 编号='" & Text1.Text & "'"
  883. .Refresh
  884. If .Recordset.AbsolutePosition <> adPosUnknown Then
  885.     Text2.Text = .Recordset.Fields(3)
  886.     Text18.Text = .Recordset.Fields(2)
  887.     Text18.Locked = True
  888.     Label23.ForeColor = &HFF&
  889.     Label23.Caption = "已经找到[" & Text1.Text & "]这个代码!"
  890.     With Adodc1
  891.     .RecordSource = "select * from " & frmmain.datas & " where 编号='" & Text1.Text & "'"
  892.     .Refresh
  893.     If .Recordset.AbsolutePosition <> adPosUnknown Then
  894.         Command1.Enabled = False
  895.         If .Recordset.Fields("数量") > 0 Then
  896.             Command2.Enabled = False
  897.             Combo1.Text = ""
  898.             Text3.Text = ""
  899.             Text4.Text = ""
  900.             Text5.Text = ""
  901.             Text6.Text = ""
  902.             Text7.Text = ""
  903.             Text17.Text = "请填写备注"
  904.             MsgBox "该药品或器械库存结余,不能继续入库!"
  905.             Text1.Locked = False
  906.             Text18.Locked = False
  907.             Text18.Text = ""
  908.             Text1.Text = ""
  909.         Else
  910.             Label23.ForeColor = &HFF0000
  911.             Label23.Caption = "库存[" & Text18.Text & "]已空,请增加库存量!"
  912.             Combo1.Locked = True
  913.             Command2.Enabled = True
  914.             Text4.Locked = True
  915.             Text5.Locked = True
  916.             Text2.Text = .Recordset.Fields("规格")
  917.             Combo1.Text = .Recordset.Fields("单位")
  918.             Text3.Text = .Recordset.Fields("数量")
  919.             Text4.Text = .Recordset.Fields("进价")
  920.             Text5.Text = .Recordset.Fields("零售价")
  921.             Text6.Text = .Recordset.Fields("产地")
  922.             Text7.Text = .Recordset.Fields("批号")
  923.         End If
  924.     Else
  925.         Label23.ForeColor = &HFF0000
  926.         Label23.Caption = "库房中没有[" & Text18.Text & "],请添加新品种!"
  927.         Command2.Enabled = False
  928.         Command1.Enabled = True
  929.         Combo1.Locked = False
  930.         Text4.Locked = False
  931.         Text5.Locked = False
  932.         Combo1.Text = ""
  933.         Text3.Text = ""
  934.         Text4.Text = ""
  935.         Text5.Text = ""
  936.         Text6.Text = ""
  937.         Text17.Text = "请填写备注"
  938.     End If
  939.     End With
  940. Else
  941. Command1.Enabled = False
  942. Command2.Enabled = False
  943. Label23.ForeColor = &H12&
  944. Label23.Caption = "代码库中没有[" & Text1.Text & "]这个代码,应先编制代码!"
  945. End If
  946. End With
  947. Exit Sub
  948. err3:
  949. MsgBox "输入了非法字符或数据项填写不完整!"
  950. End Sub
  951. Private Sub Form_Unload(Cancel As Integer)
  952. frmmain.StatusBar1.Panels(2) = "目前没有窗口被激活"
  953. End Sub
  954. Private Sub Form_Activate()
  955. frmmain.StatusBar1.Panels(2) = "活动窗口:" & frminput.Caption
  956. End Sub
  957. Private Sub Text3_GotFocus()
  958. Text3.SelStart = 0
  959. Text3.SelLength = Len(Text3.Text)
  960. End Sub
  961. Private Sub Text4_GotFocus()
  962. Text4.SelStart = 0
  963. Text4.SelLength = Len(Text4.Text)
  964. End Sub
  965. Private Sub Text5_GotFocus()
  966. Text5.SelStart = 0
  967. Text5.SelLength = Len(Text5.Text)
  968. End Sub
  969. Private Sub Text6_GotFocus()
  970. Text6.SelStart = 0
  971. Text6.SelLength = Len(Text6.Text)
  972. End Sub
  973. Private Sub Text7_GotFocus()
  974. Text7.SelStart = 0
  975. Text7.SelLength = Len(Text7.Text)
  976. End Sub
  977. Private Sub Text17_GotFocus()
  978. Text17.SelStart = 0
  979. Text17.SelLength = Len(Text17.Text)
  980. End Sub
  981. Private Sub Text1_GotFocus()
  982. Text1.SelStart = 0
  983. Text1.SelLength = Len(Text1.Text)
  984. End Sub
  985. Private Sub Text18_GotFocus()
  986. Text18.SelStart = 0
  987. Text18.SelLength = Len(Text18.Text)
  988. End Sub
  989. Private Sub Text6_Change()
  990. On Error GoTo err0
  991. With Adodc3
  992. .RecordSource = "select 名称,代码 from othercode where 代码='" & Text6.Text & "'"
  993. .Refresh
  994. If .Recordset.AbsolutePosition <> adPosUnknown Then
  995. Text6.Text = .Recordset.Fields("名称")
  996. End If
  997. End With
  998. Exit Sub
  999. err0:
  1000. MsgBox "数据库连接失败!"
  1001. End Sub
  1002. Private Sub Text18_Change()
  1003. On Error GoTo err5
  1004. With Adodc2
  1005. .RecordSource = "select * from " & frmmain.kcode & " where 代码='" & Text18.Text & "'"
  1006. .Refresh
  1007. If .Recordset.AbsolutePosition <> adPosUnknown Then
  1008.     Text1.Text = .Recordset.Fields(1)
  1009.     Text1.Locked = True
  1010. Else
  1011.     Command1.Enabled = False
  1012. End If
  1013. End With
  1014. Exit Sub
  1015. err5:
  1016. MsgBox "数据库连接失败!"
  1017. End Sub