F_PeiXunShiShiJiHua1.frm
上传用户:xiao_xia32
上传日期:2022-07-21
资源大小:1174k
文件大小:57k
源码类别:

企业管理

开发平台:

Visual Basic

  1. VERSION 5.00
  2. Object = "{86CF1D34-0C5F-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCT2.OCX"
  3. Object = "{CDE57A40-8B86-11D0-B3C6-00A0C90AEA82}#1.0#0"; "MSDATGRD.OCX"
  4. Object = "{BDC217C8-ED16-11CD-956C-0000C04E4C0A}#1.1#0"; "TABCTL32.OCX"
  5. Object = "{0BA686C6-F7D3-101A-993E-0000C0EF6F5E}#1.0#0"; "THREED32.OCX"
  6. Begin VB.Form F_PeiXunShiShiJiHua1 
  7.    BorderStyle     =   3  'Fixed Dialog
  8.    Caption         =   "培训实施计划表"
  9.    ClientHeight    =   8625
  10.    ClientLeft      =   1680
  11.    ClientTop       =   825
  12.    ClientWidth     =   11910
  13.    ControlBox      =   0   'False
  14.    KeyPreview      =   -1  'True
  15.    LinkTopic       =   "Form1"
  16.    LockControls    =   -1  'True
  17.    MaxButton       =   0   'False
  18.    MinButton       =   0   'False
  19.    Moveable        =   0   'False
  20.    ScaleHeight     =   8625
  21.    ScaleWidth      =   11910
  22.    ShowInTaskbar   =   0   'False
  23.    StartUpPosition =   2  '屏幕中心
  24.    Begin TabDlg.SSTab SSTab1 
  25.       Height          =   8535
  26.       Left            =   0
  27.       TabIndex        =   36
  28.       Top             =   0
  29.       Width           =   11775
  30.       _ExtentX        =   20770
  31.       _ExtentY        =   15055
  32.       _Version        =   393216
  33.       Tabs            =   2
  34.       TabHeight       =   520
  35.       TabCaption(0)   =   "编    辑"
  36.       TabPicture(0)   =   "F_PeiXunShiShiJiHua1.frx":0000
  37.       Tab(0).ControlEnabled=   -1  'True
  38.       Tab(0).Control(0)=   "lblLabels(1)"
  39.       Tab(0).Control(0).Enabled=   0   'False
  40.       Tab(0).Control(1)=   "lblLabels(2)"
  41.       Tab(0).Control(1).Enabled=   0   'False
  42.       Tab(0).Control(2)=   "lblLabels(4)"
  43.       Tab(0).Control(2).Enabled=   0   'False
  44.       Tab(0).Control(3)=   "txtFields(2)"
  45.       Tab(0).Control(3).Enabled=   0   'False
  46.       Tab(0).Control(4)=   "Frame9"
  47.       Tab(0).Control(4).Enabled=   0   'False
  48.       Tab(0).Control(5)=   "Frame10"
  49.       Tab(0).Control(5).Enabled=   0   'False
  50.       Tab(0).Control(6)=   "Frame11"
  51.       Tab(0).Control(6).Enabled=   0   'False
  52.       Tab(0).Control(7)=   "Frame12"
  53.       Tab(0).Control(7).Enabled=   0   'False
  54.       Tab(0).Control(8)=   "DTPicker1"
  55.       Tab(0).Control(8).Enabled=   0   'False
  56.       Tab(0).Control(9)=   "Frame8"
  57.       Tab(0).Control(9).Enabled=   0   'False
  58.       Tab(0).Control(10)=   "Frame7"
  59.       Tab(0).Control(10).Enabled=   0   'False
  60.       Tab(0).Control(11)=   "Frame5"
  61.       Tab(0).Control(11).Enabled=   0   'False
  62.       Tab(0).Control(12)=   "Frame6"
  63.       Tab(0).Control(12).Enabled=   0   'False
  64.       Tab(0).Control(13)=   "txtFields(8)"
  65.       Tab(0).Control(13).Enabled=   0   'False
  66.       Tab(0).Control(14)=   "Frame2"
  67.       Tab(0).Control(14).Enabled=   0   'False
  68.       Tab(0).Control(15)=   "Frame4"
  69.       Tab(0).Control(15).Enabled=   0   'False
  70.       Tab(0).Control(16)=   "Frame1"
  71.       Tab(0).Control(16).Enabled=   0   'False
  72.       Tab(0).Control(17)=   "Frame3"
  73.       Tab(0).Control(17).Enabled=   0   'False
  74.       Tab(0).Control(18)=   "Picture1"
  75.       Tab(0).Control(18).Enabled=   0   'False
  76.       Tab(0).ControlCount=   19
  77.       TabCaption(1)   =   "列    表"
  78.       TabPicture(1)   =   "F_PeiXunShiShiJiHua1.frx":001C
  79.       Tab(1).ControlEnabled=   0   'False
  80.       Tab(1).Control(0)=   "Frame13"
  81.       Tab(1).ControlCount=   1
  82.       Begin VB.PictureBox Picture1 
  83.          Appearance      =   0  'Flat
  84.          BorderStyle     =   0  'None
  85.          BeginProperty Font 
  86.             Name            =   "MS Sans Serif"
  87.             Size            =   8.25
  88.             Charset         =   0
  89.             Weight          =   400
  90.             Underline       =   0   'False
  91.             Italic          =   0   'False
  92.             Strikethrough   =   0   'False
  93.          EndProperty
  94.          ForeColor       =   &H80000008&
  95.          Height          =   440
  96.          Left            =   3720
  97.          ScaleHeight     =   435
  98.          ScaleWidth      =   7080
  99.          TabIndex        =   90
  100.          Top             =   8040
  101.          Width           =   7080
  102.          Begin Threed.SSCommand cmdClose 
  103.             Height          =   330
  104.             Left            =   5640
  105.             TabIndex        =   91
  106.             Top             =   0
  107.             Width           =   1095
  108.             _Version        =   65536
  109.             _ExtentX        =   1931
  110.             _ExtentY        =   573
  111.             _StockProps     =   78
  112.             Caption         =   "&Q.关 闭"
  113.             Font3D          =   1
  114.          End
  115.          Begin Threed.SSCommand cmdRefresh 
  116.             Height          =   330
  117.             Left            =   4440
  118.             TabIndex        =   92
  119.             Top             =   0
  120.             Width           =   1095
  121.             _Version        =   65536
  122.             _ExtentX        =   1931
  123.             _ExtentY        =   573
  124.             _StockProps     =   78
  125.             Caption         =   "&R.刷 新"
  126.             Font3D          =   1
  127.          End
  128.          Begin Threed.SSCommand CmdAdd 
  129.             Height          =   330
  130.             Left            =   840
  131.             TabIndex        =   93
  132.             Top             =   0
  133.             Width           =   1095
  134.             _Version        =   65536
  135.             _ExtentX        =   1931
  136.             _ExtentY        =   582
  137.             _StockProps     =   78
  138.             Caption         =   "&A.增 加"
  139.             Font3D          =   1
  140.             Picture         =   "F_PeiXunShiShiJiHua1.frx":0038
  141.          End
  142.          Begin Threed.SSCommand cmdEdit 
  143.             Height          =   330
  144.             Left            =   2040
  145.             TabIndex        =   94
  146.             Top             =   0
  147.             Width           =   1095
  148.             _Version        =   65536
  149.             _ExtentX        =   1931
  150.             _ExtentY        =   573
  151.             _StockProps     =   78
  152.             Caption         =   "&E.编 辑"
  153.             Font3D          =   1
  154.          End
  155.          Begin Threed.SSCommand CmdDelete 
  156.             Height          =   330
  157.             Left            =   3240
  158.             TabIndex        =   95
  159.             Top             =   0
  160.             Width           =   1095
  161.             _Version        =   65536
  162.             _ExtentX        =   1931
  163.             _ExtentY        =   573
  164.             _StockProps     =   78
  165.             Caption         =   "&D.删 除"
  166.             Font3D          =   1
  167.          End
  168.          Begin Threed.SSCommand cmdCancel 
  169.             Height          =   330
  170.             Left            =   5640
  171.             TabIndex        =   96
  172.             Top             =   0
  173.             Width           =   1095
  174.             _Version        =   65536
  175.             _ExtentX        =   1931
  176.             _ExtentY        =   573
  177.             _StockProps     =   78
  178.             Caption         =   "&C.取消"
  179.             Font3D          =   1
  180.          End
  181.          Begin Threed.SSCommand cmdUpdate 
  182.             Height          =   330
  183.             Left            =   4440
  184.             TabIndex        =   97
  185.             Top             =   0
  186.             Width           =   1095
  187.             _Version        =   65536
  188.             _ExtentX        =   1931
  189.             _ExtentY        =   573
  190.             _StockProps     =   78
  191.             Caption         =   "&Y.保存"
  192.             Font3D          =   1
  193.          End
  194.       End
  195.       Begin VB.Frame Frame3 
  196.          Height          =   1335
  197.          Left            =   600
  198.          TabIndex        =   39
  199.          Top             =   720
  200.          Width           =   10935
  201.          Begin VB.TextBox txtFields 
  202.             Appearance      =   0  'Flat
  203.             DataField       =   "培训计划编号"
  204.             Height          =   285
  205.             Index           =   0
  206.             Left            =   1680
  207.             TabIndex        =   3
  208.             Top             =   240
  209.             Width           =   1455
  210.          End
  211.          Begin MSComCtl2.DTPicker DTPicker2 
  212.             DataField       =   "举办日期"
  213.             Height          =   300
  214.             Left            =   5400
  215.             TabIndex        =   7
  216.             Top             =   600
  217.             Width           =   1455
  218.             _ExtentX        =   2566
  219.             _ExtentY        =   529
  220.             _Version        =   393216
  221.             CheckBox        =   -1  'True
  222.             DateIsNull      =   -1  'True
  223.             Format          =   64290817
  224.             CurrentDate     =   36186
  225.          End
  226.          Begin VB.TextBox txtFields 
  227.             Appearance      =   0  'Flat
  228.             DataField       =   "项目名称"
  229.             Height          =   285
  230.             Index           =   3
  231.             Left            =   5400
  232.             TabIndex        =   4
  233.             Top             =   240
  234.             Width           =   1455
  235.          End
  236.          Begin VB.TextBox txtFields 
  237.             Appearance      =   0  'Flat
  238.             DataField       =   "培训种类"
  239.             Height          =   285
  240.             Index           =   5
  241.             Left            =   9240
  242.             TabIndex        =   5
  243.             Top             =   240
  244.             Width           =   1455
  245.          End
  246.          Begin VB.TextBox txtFields 
  247.             Appearance      =   0  'Flat
  248.             DataField       =   "培训对象"
  249.             Height          =   285
  250.             Index           =   6
  251.             Left            =   1680
  252.             TabIndex        =   6
  253.             Top             =   600
  254.             Width           =   1455
  255.          End
  256.          Begin VB.TextBox txtFields 
  257.             Appearance      =   0  'Flat
  258.             DataField       =   "参加人数"
  259.             Height          =   285
  260.             Index           =   7
  261.             Left            =   1680
  262.             TabIndex        =   9
  263.             Top             =   960
  264.             Width           =   1455
  265.          End
  266.          Begin VB.TextBox txtFields 
  267.             Appearance      =   0  'Flat
  268.             DataField       =   "地点"
  269.             Height          =   285
  270.             Index           =   9
  271.             Left            =   9240
  272.             TabIndex        =   8
  273.             Top             =   600
  274.             Width           =   1455
  275.          End
  276.          Begin VB.TextBox txtFields 
  277.             Appearance      =   0  'Flat
  278.             DataField       =   "培训时数"
  279.             Height          =   285
  280.             Index           =   10
  281.             Left            =   5400
  282.             TabIndex        =   10
  283.             Top             =   960
  284.             Width           =   1455
  285.          End
  286.          Begin VB.TextBox txtFields 
  287.             Appearance      =   0  'Flat
  288.             DataField       =   "师资来源"
  289.             Height          =   285
  290.             Index           =   11
  291.             Left            =   9240
  292.             TabIndex        =   11
  293.             Top             =   960
  294.             Width           =   1455
  295.          End
  296.          Begin VB.Label lblLabels 
  297.             Caption         =   "计划编号"
  298.             Height          =   255
  299.             Index           =   0
  300.             Left            =   120
  301.             TabIndex        =   86
  302.             Top             =   240
  303.             Width           =   975
  304.          End
  305.          Begin VB.Label lblLabels 
  306.             Caption         =   "项目名称"
  307.             Height          =   255
  308.             Index           =   3
  309.             Left            =   3720
  310.             TabIndex        =   47
  311.             Top             =   240
  312.             Width           =   855
  313.          End
  314.          Begin VB.Label lblLabels 
  315.             Caption         =   "培训种类"
  316.             Height          =   255
  317.             Index           =   5
  318.             Left            =   7560
  319.             TabIndex        =   46
  320.             Top             =   240
  321.             Width           =   855
  322.          End
  323.          Begin VB.Label lblLabels 
  324.             Caption         =   "培训对象"
  325.             Height          =   255
  326.             Index           =   6
  327.             Left            =   120
  328.             TabIndex        =   45
  329.             Top             =   600
  330.             Width           =   735
  331.          End
  332.          Begin VB.Label lblLabels 
  333.             Caption         =   "参加人数"
  334.             Height          =   255
  335.             Index           =   7
  336.             Left            =   120
  337.             TabIndex        =   44
  338.             Top             =   960
  339.             Width           =   735
  340.          End
  341.          Begin VB.Label lblLabels 
  342.             Caption         =   "举办日期"
  343.             Height          =   255
  344.             Index           =   8
  345.             Left            =   3720
  346.             TabIndex        =   43
  347.             Top             =   600
  348.             Width           =   735
  349.          End
  350.          Begin VB.Label lblLabels 
  351.             Caption         =   "地  点"
  352.             Height          =   255
  353.             Index           =   9
  354.             Left            =   7560
  355.             TabIndex        =   42
  356.             Top             =   600
  357.             Width           =   615
  358.          End
  359.          Begin VB.Label lblLabels 
  360.             Caption         =   "培训时数"
  361.             Height          =   255
  362.             Index           =   10
  363.             Left            =   3720
  364.             TabIndex        =   41
  365.             Top             =   960
  366.             Width           =   735
  367.          End
  368.          Begin VB.Label lblLabels 
  369.             Caption         =   "师资来源"
  370.             Height          =   255
  371.             Index           =   11
  372.             Left            =   7560
  373.             TabIndex        =   40
  374.             Top             =   960
  375.             Width           =   855
  376.          End
  377.       End
  378.       Begin VB.Frame Frame1 
  379.          Height          =   1215
  380.          Left            =   600
  381.          TabIndex        =   88
  382.          Top             =   1920
  383.          Width           =   10935
  384.          Begin VB.TextBox txtFields 
  385.             DataField       =   "培训目的"
  386.             Height          =   1095
  387.             Index           =   1
  388.             Left            =   0
  389.             MultiLine       =   -1  'True
  390.             ScrollBars      =   2  'Vertical
  391.             TabIndex        =   89
  392.             Top             =   120
  393.             Width           =   10935
  394.          End
  395.       End
  396.       Begin VB.Frame Frame4 
  397.          Height          =   855
  398.          Left            =   600
  399.          TabIndex        =   53
  400.          Top             =   3000
  401.          Width           =   10935
  402.          Begin VB.TextBox txtFields 
  403.             Appearance      =   0  'Flat
  404.             DataField       =   "课时费"
  405.             Height          =   285
  406.             Index           =   13
  407.             Left            =   120
  408.             TabIndex        =   12
  409.             Top             =   480
  410.             Width           =   855
  411.          End
  412.          Begin VB.TextBox txtFields 
  413.             Appearance      =   0  'Flat
  414.             DataField       =   "租用费"
  415.             Height          =   285
  416.             Index           =   14
  417.             Left            =   1680
  418.             TabIndex        =   13
  419.             Top             =   480
  420.             Width           =   855
  421.          End
  422.          Begin VB.TextBox txtFields 
  423.             Appearance      =   0  'Flat
  424.             DataField       =   "招待费"
  425.             Height          =   285
  426.             Index           =   15
  427.             Left            =   3120
  428.             TabIndex        =   14
  429.             Top             =   480
  430.             Width           =   855
  431.          End
  432.          Begin VB.TextBox txtFields 
  433.             Appearance      =   0  'Flat
  434.             DataField       =   "交通费"
  435.             Height          =   285
  436.             Index           =   16
  437.             Left            =   4440
  438.             TabIndex        =   15
  439.             Top             =   480
  440.             Width           =   855
  441.          End
  442.          Begin VB.TextBox txtFields 
  443.             Appearance      =   0  'Flat
  444.             DataField       =   "教材费"
  445.             Height          =   285
  446.             Index           =   17
  447.             Left            =   5880
  448.             TabIndex        =   16
  449.             Top             =   480
  450.             Width           =   855
  451.          End
  452.          Begin VB.TextBox txtFields 
  453.             Appearance      =   0  'Flat
  454.             DataField       =   "工时占用费用"
  455.             Height          =   285
  456.             Index           =   18
  457.             Left            =   7200
  458.             TabIndex        =   17
  459.             Top             =   480
  460.             Width           =   855
  461.          End
  462.          Begin VB.TextBox txtFields 
  463.             Appearance      =   0  'Flat
  464.             DataField       =   "其他费用"
  465.             Height          =   285
  466.             Index           =   19
  467.             Left            =   8520
  468.             TabIndex        =   18
  469.             Top             =   480
  470.             Width           =   855
  471.          End
  472.          Begin VB.TextBox txtFields 
  473.             Appearance      =   0  'Flat
  474.             DataField       =   "预算费用合计"
  475.             Height          =   285
  476.             Index           =   20
  477.             Left            =   9840
  478.             TabIndex        =   19
  479.             Top             =   480
  480.             Width           =   855
  481.          End
  482.          Begin VB.Label lblLabels 
  483.             Caption         =   "课时费:"
  484.             Height          =   255
  485.             Index           =   13
  486.             Left            =   120
  487.             TabIndex        =   61
  488.             Top             =   240
  489.             Width           =   615
  490.          End
  491.          Begin VB.Label lblLabels 
  492.             Caption         =   "租用费:"
  493.             Height          =   255
  494.             Index           =   14
  495.             Left            =   1680
  496.             TabIndex        =   60
  497.             Top             =   240
  498.             Width           =   615
  499.          End
  500.          Begin VB.Label lblLabels 
  501.             Caption         =   "招待费:"
  502.             Height          =   255
  503.             Index           =   15
  504.             Left            =   3240
  505.             TabIndex        =   59
  506.             Top             =   240
  507.             Width           =   615
  508.          End
  509.          Begin VB.Label lblLabels 
  510.             Caption         =   "交通费:"
  511.             Height          =   255
  512.             Index           =   16
  513.             Left            =   4440
  514.             TabIndex        =   58
  515.             Top             =   240
  516.             Width           =   615
  517.          End
  518.          Begin VB.Label lblLabels 
  519.             Caption         =   "教材费:"
  520.             Height          =   255
  521.             Index           =   17
  522.             Left            =   5880
  523.             TabIndex        =   57
  524.             Top             =   240
  525.             Width           =   615
  526.          End
  527.          Begin VB.Label lblLabels 
  528.             Caption         =   "工时占用"
  529.             Height          =   255
  530.             Index           =   18
  531.             Left            =   7200
  532.             TabIndex        =   56
  533.             Top             =   240
  534.             Width           =   855
  535.          End
  536.          Begin VB.Label lblLabels 
  537.             Caption         =   "其  他"
  538.             Height          =   255
  539.             Index           =   19
  540.             Left            =   8520
  541.             TabIndex        =   55
  542.             Top             =   240
  543.             Width           =   975
  544.          End
  545.          Begin VB.Label lblLabels 
  546.             Caption         =   "预算合计"
  547.             Height          =   255
  548.             Index           =   20
  549.             Left            =   9720
  550.             TabIndex        =   54
  551.             Top             =   240
  552.             Width           =   735
  553.          End
  554.       End
  555.       Begin VB.Frame Frame2 
  556.          Height          =   1215
  557.          Left            =   600
  558.          TabIndex        =   48
  559.          Top             =   3720
  560.          Width           =   10935
  561.          Begin VB.TextBox txtFields 
  562.             DataField       =   "培训内容"
  563.             Height          =   645
  564.             Index           =   4
  565.             Left            =   0
  566.             MultiLine       =   -1  'True
  567.             ScrollBars      =   2  'Vertical
  568.             TabIndex        =   85
  569.             Top             =   120
  570.             Width           =   10935
  571.          End
  572.          Begin VB.CheckBox Check3 
  573.             Caption         =   "实际操作"
  574.             DataField       =   "实际操作"
  575.             Height          =   255
  576.             Left            =   8520
  577.             TabIndex        =   51
  578.             Top             =   840
  579.             Width           =   1575
  580.          End
  581.          Begin VB.CheckBox Check2 
  582.             Caption         =   "笔试"
  583.             DataField       =   "笔试"
  584.             Height          =   255
  585.             Left            =   6000
  586.             TabIndex        =   50
  587.             Top             =   840
  588.             Width           =   1095
  589.          End
  590.          Begin VB.CheckBox Check1 
  591.             Caption         =   "口试"
  592.             DataField       =   "口试"
  593.             Height          =   255
  594.             Left            =   3120
  595.             TabIndex        =   49
  596.             Top             =   840
  597.             Width           =   975
  598.          End
  599.          Begin VB.Label lblLabels 
  600.             Caption         =   "考核方式:"
  601.             Height          =   255
  602.             Index           =   22
  603.             Left            =   360
  604.             TabIndex        =   52
  605.             Top             =   840
  606.             Width           =   855
  607.          End
  608.       End
  609.       Begin VB.TextBox txtFields 
  610.          Appearance      =   0  'Flat
  611.          DataField       =   "实施计划编号"
  612.          Height          =   285
  613.          Index           =   8
  614.          Left            =   2280
  615.          TabIndex        =   0
  616.          Top             =   400
  617.          Width           =   1455
  618.       End
  619.       Begin VB.Frame Frame6 
  620.          Height          =   1335
  621.          Left            =   120
  622.          TabIndex        =   64
  623.          Top             =   720
  624.          Width           =   495
  625.          Begin VB.Label Label1 
  626.             Caption         =   "项目信息"
  627.             Height          =   855
  628.             Left            =   120
  629.             TabIndex        =   65
  630.             Top             =   240
  631.             Width           =   255
  632.          End
  633.       End
  634.       Begin VB.Frame Frame5 
  635.          Height          =   1215
  636.          Left            =   120
  637.          TabIndex        =   62
  638.          Top             =   1920
  639.          Width           =   495
  640.          Begin VB.Label lblLabels 
  641.             Caption         =   "培训目的"
  642.             Height          =   855
  643.             Index           =   12
  644.             Left            =   120
  645.             TabIndex        =   63
  646.             Top             =   240
  647.             Width           =   255
  648.          End
  649.       End
  650.       Begin VB.Frame Frame7 
  651.          Height          =   855
  652.          Left            =   120
  653.          TabIndex        =   66
  654.          Top             =   3000
  655.          Width           =   495
  656.          Begin VB.Label Label2 
  657.             Caption         =   "费用"
  658.             Height          =   495
  659.             Left            =   120
  660.             TabIndex        =   67
  661.             Top             =   240
  662.             Width           =   255
  663.          End
  664.       End
  665.       Begin VB.Frame Frame8 
  666.          Height          =   1215
  667.          Left            =   120
  668.          TabIndex        =   68
  669.          Top             =   3720
  670.          Width           =   495
  671.          Begin VB.Label lblLabels 
  672.             Caption         =   "培训内容"
  673.             Height          =   855
  674.             Index           =   21
  675.             Left            =   120
  676.             TabIndex        =   69
  677.             Top             =   240
  678.             Width           =   255
  679.          End
  680.       End
  681.       Begin MSComCtl2.DTPicker DTPicker1 
  682.          DataField       =   "时间"
  683.          Height          =   300
  684.          Left            =   9840
  685.          TabIndex        =   2
  686.          Top             =   405
  687.          Width           =   1455
  688.          _ExtentX        =   2566
  689.          _ExtentY        =   529
  690.          _Version        =   393216
  691.          CheckBox        =   -1  'True
  692.          Format          =   64290817
  693.          CurrentDate     =   36186
  694.       End
  695.       Begin VB.Frame Frame13 
  696.          Height          =   7695
  697.          Left            =   -74760
  698.          TabIndex        =   83
  699.          Top             =   600
  700.          Width           =   11295
  701.          Begin MSDataGridLib.DataGrid DataGrid2 
  702.             Height          =   7215
  703.             Left            =   240
  704.             TabIndex        =   84
  705.             Top             =   240
  706.             Width           =   10815
  707.             _ExtentX        =   19076
  708.             _ExtentY        =   12726
  709.             _Version        =   393216
  710.             AllowUpdate     =   0   'False
  711.             HeadLines       =   1
  712.             RowHeight       =   14
  713.             BeginProperty HeadFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  714.                Name            =   "MS Sans Serif"
  715.                Size            =   8.25
  716.                Charset         =   0
  717.                Weight          =   400
  718.                Underline       =   0   'False
  719.                Italic          =   0   'False
  720.                Strikethrough   =   0   'False
  721.             EndProperty
  722.             BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  723.                Name            =   "宋体"
  724.                Size            =   9
  725.                Charset         =   134
  726.                Weight          =   400
  727.                Underline       =   0   'False
  728.                Italic          =   0   'False
  729.                Strikethrough   =   0   'False
  730.             EndProperty
  731.             ColumnCount     =   2
  732.             BeginProperty Column00 
  733.                DataField       =   ""
  734.                Caption         =   ""
  735.                BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  736.                   Type            =   0
  737.                   Format          =   ""
  738.                   HaveTrueFalseNull=   0
  739.                   FirstDayOfWeek  =   0
  740.                   FirstWeekOfYear =   0
  741.                   LCID            =   2052
  742.                   SubFormatType   =   0
  743.                EndProperty
  744.             EndProperty
  745.             BeginProperty Column01 
  746.                DataField       =   ""
  747.                Caption         =   ""
  748.                BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  749.                   Type            =   0
  750.                   Format          =   ""
  751.                   HaveTrueFalseNull=   0
  752.                   FirstDayOfWeek  =   0
  753.                   FirstWeekOfYear =   0
  754.                   LCID            =   2052
  755.                   SubFormatType   =   0
  756.                EndProperty
  757.             EndProperty
  758.             SplitCount      =   1
  759.             BeginProperty Split0 
  760.                BeginProperty Column00 
  761.                EndProperty
  762.                BeginProperty Column01 
  763.                EndProperty
  764.             EndProperty
  765.          End
  766.       End
  767.       Begin VB.Frame Frame12 
  768.          Height          =   2055
  769.          Left            =   120
  770.          TabIndex        =   81
  771.          Top             =   4800
  772.          Width           =   495
  773.          Begin VB.Label Label7 
  774.             Caption         =   "受训人员"
  775.             Height          =   855
  776.             Left            =   120
  777.             TabIndex        =   82
  778.             Top             =   600
  779.             Width           =   255
  780.          End
  781.       End
  782.       Begin VB.Frame Frame11 
  783.          Height          =   2055
  784.          Left            =   600
  785.          TabIndex        =   79
  786.          Top             =   4800
  787.          Width           =   10935
  788.          Begin MSDataGridLib.DataGrid DataGrid1 
  789.             Height          =   1935
  790.             Left            =   0
  791.             TabIndex        =   80
  792.             Top             =   120
  793.             Width           =   10935
  794.             _ExtentX        =   19288
  795.             _ExtentY        =   3413
  796.             _Version        =   393216
  797.             HeadLines       =   1
  798.             RowHeight       =   14
  799.             TabAction       =   2
  800.             FormatLocked    =   -1  'True
  801.             BeginProperty HeadFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  802.                Name            =   "MS Sans Serif"
  803.                Size            =   8.25
  804.                Charset         =   0
  805.                Weight          =   400
  806.                Underline       =   0   'False
  807.                Italic          =   0   'False
  808.                Strikethrough   =   0   'False
  809.             EndProperty
  810.             BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  811.                Name            =   "宋体"
  812.                Size            =   9
  813.                Charset         =   134
  814.                Weight          =   400
  815.                Underline       =   0   'False
  816.                Italic          =   0   'False
  817.                Strikethrough   =   0   'False
  818.             EndProperty
  819.             ColumnCount     =   3
  820.             BeginProperty Column00 
  821.                DataField       =   "员工号"
  822.                Caption         =   "员工号"
  823.                BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  824.                   Type            =   0
  825.                   Format          =   ""
  826.                   HaveTrueFalseNull=   0
  827.                   FirstDayOfWeek  =   0
  828.                   FirstWeekOfYear =   0
  829.                   LCID            =   2052
  830.                   SubFormatType   =   0
  831.                EndProperty
  832.             EndProperty
  833.             BeginProperty Column01 
  834.                DataField       =   "姓名"
  835.                Caption         =   "姓名"
  836.                BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  837.                   Type            =   0
  838.                   Format          =   ""
  839.                   HaveTrueFalseNull=   0
  840.                   FirstDayOfWeek  =   0
  841.                   FirstWeekOfYear =   0
  842.                   LCID            =   2052
  843.                   SubFormatType   =   0
  844.                EndProperty
  845.             EndProperty
  846.             BeginProperty Column02 
  847.                DataField       =   "岗位"
  848.                Caption         =   "岗位"
  849.                BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  850.                   Type            =   0
  851.                   Format          =   ""
  852.                   HaveTrueFalseNull=   0
  853.                   FirstDayOfWeek  =   0
  854.                   FirstWeekOfYear =   0
  855.                   LCID            =   2052
  856.                   SubFormatType   =   0
  857.                EndProperty
  858.             EndProperty
  859.             SplitCount      =   1
  860.             BeginProperty Split0 
  861.                BeginProperty Column00 
  862.                   ColumnWidth     =   1395.213
  863.                EndProperty
  864.                BeginProperty Column01 
  865.                   ColumnWidth     =   1739.906
  866.                EndProperty
  867.                BeginProperty Column02 
  868.                   ColumnWidth     =   1739.906
  869.                EndProperty
  870.             EndProperty
  871.          End
  872.       End
  873.       Begin VB.Frame Frame10 
  874.          Height          =   1215
  875.          Left            =   120
  876.          TabIndex        =   77
  877.          Top             =   6720
  878.          Width           =   495
  879.          Begin VB.Label Label6 
  880.             Caption         =   "呈核"
  881.             Height          =   495
  882.             Left            =   120
  883.             TabIndex        =   78
  884.             Top             =   480
  885.             Width           =   255
  886.          End
  887.       End
  888.       Begin VB.Frame Frame9 
  889.          Height          =   1215
  890.          Left            =   600
  891.          TabIndex        =   70
  892.          Top             =   6720
  893.          Width           =   10935
  894.          Begin MSComCtl2.DTPicker DTPicker6 
  895.             DataField       =   "部门申请人签字时间"
  896.             Height          =   300
  897.             Left            =   9240
  898.             TabIndex        =   27
  899.             Top             =   840
  900.             Width           =   1455
  901.             _ExtentX        =   2566
  902.             _ExtentY        =   529
  903.             _Version        =   393216
  904.             CheckBox        =   -1  'True
  905.             Format          =   64290817
  906.             CurrentDate     =   36186
  907.          End
  908.          Begin MSComCtl2.DTPicker DTPicker5 
  909.             DataField       =   "总经理签字时间"
  910.             Height          =   300
  911.             Left            =   6720
  912.             TabIndex        =   26
  913.             Top             =   840
  914.             Width           =   1455
  915.             _ExtentX        =   2566
  916.             _ExtentY        =   529
  917.             _Version        =   393216
  918.             CheckBox        =   -1  'True
  919.             Format          =   64290817
  920.             CurrentDate     =   36186
  921.          End
  922.          Begin MSComCtl2.DTPicker DTPicker4 
  923.             DataField       =   "财务部签字时间"
  924.             Height          =   300
  925.             Left            =   4080
  926.             TabIndex        =   25
  927.             Top             =   840
  928.             Width           =   1455
  929.             _ExtentX        =   2566
  930.             _ExtentY        =   529
  931.             _Version        =   393216
  932.             CheckBox        =   -1  'True
  933.             Format          =   64290817
  934.             CurrentDate     =   36186
  935.          End
  936.          Begin MSComCtl2.DTPicker DTPicker3 
  937.             DataField       =   "人力资源部签字时间"
  938.             Height          =   300
  939.             Left            =   1200
  940.             TabIndex        =   24
  941.             Top             =   840
  942.             Width           =   1455
  943.             _ExtentX        =   2566
  944.             _ExtentY        =   529
  945.             _Version        =   393216
  946.             CheckBox        =   -1  'True
  947.             Format          =   64290817
  948.             CurrentDate     =   36186
  949.          End
  950.          Begin VB.TextBox txtFields 
  951.             Appearance      =   0  'Flat
  952.             DataField       =   "人力资源部经理签字"
  953.             Height          =   285
  954.             Index           =   23
  955.             Left            =   1200
  956.             TabIndex        =   20
  957.             Top             =   480
  958.             Width           =   1455
  959.          End
  960.          Begin VB.TextBox txtFields 
  961.             Appearance      =   0  'Flat
  962.             DataField       =   "财务部经理签字"
  963.             Height          =   285
  964.             Index           =   25
  965.             Left            =   4080
  966.             TabIndex        =   21
  967.             Top             =   480
  968.             Width           =   1455
  969.          End
  970.          Begin VB.TextBox txtFields 
  971.             Appearance      =   0  'Flat
  972.             DataField       =   "总经理签字"
  973.             Height          =   285
  974.             Index           =   12
  975.             Left            =   6720
  976.             TabIndex        =   22
  977.             Top             =   480
  978.             Width           =   1455
  979.          End
  980.          Begin VB.TextBox txtFields 
  981.             Appearance      =   0  'Flat
  982.             DataField       =   "部门申请人签字"
  983.             Height          =   285
  984.             Index           =   31
  985.             Left            =   9240
  986.             TabIndex        =   23
  987.             Top             =   480
  988.             Width           =   1455
  989.          End
  990.          Begin VB.Label lblLabels 
  991.             Caption         =   "人力资源部"
  992.             Height          =   255
  993.             Index           =   23
  994.             Left            =   1200
  995.             TabIndex        =   76
  996.             Top             =   240
  997.             Width           =   1095
  998.          End
  999.          Begin VB.Label lblLabels 
  1000.             Caption         =   "签字时间"
  1001.             Height          =   255
  1002.             Index           =   24
  1003.             Left            =   240
  1004.             TabIndex        =   75
  1005.             Top             =   840
  1006.             Width           =   855
  1007.          End
  1008.          Begin VB.Label lblLabels 
  1009.             Caption         =   "财务部"
  1010.             Height          =   255
  1011.             Index           =   25
  1012.             Left            =   4080
  1013.             TabIndex        =   74
  1014.             Top             =   240
  1015.             Width           =   975
  1016.          End
  1017.          Begin VB.Label Label3 
  1018.             Caption         =   "总经理"
  1019.             Height          =   255
  1020.             Left            =   6720
  1021.             TabIndex        =   73
  1022.             Top             =   240
  1023.             Width           =   975
  1024.          End
  1025.          Begin VB.Label Label4 
  1026.             Caption         =   "部门申请人"
  1027.             Height          =   255
  1028.             Left            =   9240
  1029.             TabIndex        =   72
  1030.             Top             =   240
  1031.             Width           =   1095
  1032.          End
  1033.          Begin VB.Label Label5 
  1034.             Caption         =   "经理签字"
  1035.             Height          =   255
  1036.             Left            =   240
  1037.             TabIndex        =   71
  1038.             Top             =   480
  1039.             Width           =   855
  1040.          End
  1041.       End
  1042.       Begin VB.TextBox txtFields 
  1043.          Appearance      =   0  'Flat
  1044.          DataField       =   "部门"
  1045.          Height          =   285
  1046.          Index           =   2
  1047.          Left            =   6000
  1048.          TabIndex        =   1
  1049.          Top             =   400
  1050.          Width           =   1455
  1051.       End
  1052.       Begin VB.Label lblLabels 
  1053.          Caption         =   "实施计划编号:"
  1054.          Height          =   255
  1055.          Index           =   4
  1056.          Left            =   720
  1057.          TabIndex        =   87
  1058.          Top             =   480
  1059.          Width           =   1095
  1060.       End
  1061.       Begin VB.Label lblLabels 
  1062.          Caption         =   "部  门"
  1063.          Height          =   255
  1064.          Index           =   2
  1065.          Left            =   4320
  1066.          TabIndex        =   38
  1067.          Top             =   480
  1068.          Width           =   855
  1069.       End
  1070.       Begin VB.Label lblLabels 
  1071.          Caption         =   "时 间"
  1072.          Height          =   255
  1073.          Index           =   1
  1074.          Left            =   8160
  1075.          TabIndex        =   37
  1076.          Top             =   480
  1077.          Width           =   615
  1078.       End
  1079.    End
  1080.    Begin VB.TextBox txtFields 
  1081.       DataField       =   "部门申请人签字时间"
  1082.       Height          =   285
  1083.       Index           =   30
  1084.       Left            =   2040
  1085.       TabIndex        =   34
  1086.       Top             =   9660
  1087.       Width           =   3375
  1088.    End
  1089.    Begin VB.TextBox txtFields 
  1090.       DataField       =   "部门申请人签字"
  1091.       Height          =   285
  1092.       Index           =   29
  1093.       Left            =   2040
  1094.       TabIndex        =   32
  1095.       Top             =   9340
  1096.       Width           =   3375
  1097.    End
  1098.    Begin VB.TextBox txtFields 
  1099.       DataField       =   "总经理签字时间"
  1100.       Height          =   285
  1101.       Index           =   28
  1102.       Left            =   2040
  1103.       TabIndex        =   30
  1104.       Top             =   9020
  1105.       Width           =   3375
  1106.    End
  1107.    Begin VB.TextBox txtFields 
  1108.       DataField       =   "总经理签字"
  1109.       Height          =   285
  1110.       Index           =   27
  1111.       Left            =   2040
  1112.       TabIndex        =   28
  1113.       Top             =   8700
  1114.       Width           =   3375
  1115.    End
  1116.    Begin MSDataGridLib.DataGrid grdDataGrid 
  1117.       Height          =   1300
  1118.       Left            =   0
  1119.       TabIndex        =   35
  1120.       Top             =   9980
  1121.       Width           =   5765
  1122.       _ExtentX        =   10160
  1123.       _ExtentY        =   2302
  1124.       _Version        =   393216
  1125.       AllowUpdate     =   0   'False
  1126.       HeadLines       =   1
  1127.       RowHeight       =   15
  1128.       BeginProperty HeadFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  1129.          Name            =   "MS Sans Serif"
  1130.          Size            =   8.25
  1131.          Charset         =   0
  1132.          Weight          =   400
  1133.          Underline       =   0   'False
  1134.          Italic          =   0   'False
  1135.          Strikethrough   =   0   'False
  1136.       EndProperty
  1137.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  1138.          Name            =   "MS Sans Serif"
  1139.          Size            =   8.25
  1140.          Charset         =   0
  1141.          Weight          =   400
  1142.          Underline       =   0   'False
  1143.          Italic          =   0   'False
  1144.          Strikethrough   =   0   'False
  1145.       EndProperty
  1146.       ColumnCount     =   2
  1147.       BeginProperty Column00 
  1148.          DataField       =   ""
  1149.          Caption         =   ""
  1150.          BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  1151.             Type            =   0
  1152.             Format          =   ""
  1153.             HaveTrueFalseNull=   0
  1154.             FirstDayOfWeek  =   0
  1155.             FirstWeekOfYear =   0
  1156.             LCID            =   2052
  1157.             SubFormatType   =   0
  1158.          EndProperty
  1159.       EndProperty
  1160.       BeginProperty Column01 
  1161.          DataField       =   ""
  1162.          Caption         =   ""
  1163.          BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
  1164.             Type            =   0
  1165.             Format          =   ""
  1166.             HaveTrueFalseNull=   0
  1167.             FirstDayOfWeek  =   0
  1168.             FirstWeekOfYear =   0
  1169.             LCID            =   2052
  1170.             SubFormatType   =   0
  1171.          EndProperty
  1172.       EndProperty
  1173.       SplitCount      =   1
  1174.       BeginProperty Split0 
  1175.          BeginProperty Column00 
  1176.          EndProperty
  1177.          BeginProperty Column01 
  1178.          EndProperty
  1179.       EndProperty
  1180.    End
  1181.    Begin VB.Label lblLabels 
  1182.       Caption         =   "部门申请人签字时间:"
  1183.       Height          =   255
  1184.       Index           =   30
  1185.       Left            =   120
  1186.       TabIndex        =   33
  1187.       Top             =   9660
  1188.       Width           =   1815
  1189.    End
  1190.    Begin VB.Label lblLabels 
  1191.       Caption         =   "部门申请人签字:"
  1192.       Height          =   255
  1193.       Index           =   29
  1194.       Left            =   120
  1195.       TabIndex        =   31
  1196.       Top             =   9340
  1197.       Width           =   1815
  1198.    End
  1199.    Begin VB.Label lblLabels 
  1200.       Caption         =   "总经理签字时间:"
  1201.       Height          =   255
  1202.       Index           =   28
  1203.       Left            =   120
  1204.       TabIndex        =   29
  1205.       Top             =   9020
  1206.       Width           =   1815
  1207.    End
  1208. End
  1209. Attribute VB_Name = "F_PeiXunShiShiJiHua1"
  1210. Attribute VB_GlobalNameSpace = False
  1211. Attribute VB_Creatable = False
  1212. Attribute VB_PredeclaredId = True
  1213. Attribute VB_Exposed = False
  1214. Dim WithEvents adoPrimaryRS As Recordset
  1215. Attribute adoPrimaryRS.VB_VarHelpID = -1
  1216. Dim mvBookMark As Variant
  1217. Dim mbEditFlag As Boolean
  1218. Dim mbAddNewFlag As Boolean
  1219. Private Function UpdateData() As Boolean
  1220.   Dim strTemp As String
  1221.   Dim adochild As ADODB.Recordset
  1222.   On Error GoTo UpdateErr
  1223.   
  1224.   '更新父表
  1225.   adoPrimaryRS.UpdateBatch adAffectCurrent
  1226.  
  1227.   '检查子表的有效性
  1228.   Set adochild = New Recordset
  1229.   Set adochild = adoPrimaryRS("ChildCMD").UnderlyingValue
  1230.   
  1231.   If Not (adochild.BOF And adochild.EOF) Then
  1232.     adochild.MoveFirst
  1233.   End If
  1234.   
  1235.   'While Not adochild.EOF
  1236.       
  1237.    '   If Trim(adochild.Fields("单价")) = "" Or IsNull(adochild.Fields("单价")) Or Not IsNumeric(adochild.Fields("单价")) Then
  1238.     '     MsgBox "请在单价中输入数字!", vbExclamation + vbOKOnly, "警告"
  1239.      '    adochild.Close
  1240.          '   Set adochild = Nothing
  1241.          'Exit Function
  1242.       'End If
  1243.       
  1244.       'If Trim(adochild.Fields("数量")) = "" Or IsNull(adochild.Fields("数量")) Or Not IsNumeric(adochild.Fields("单价")) Then
  1245.          '  MsgBox "请在数量中输入数字!", vbExclamation + vbOKOnly, "警告"
  1246.         ' adochild.Close
  1247.         ' Set adochild = Nothing
  1248.          'Exit Function
  1249.      ' End If
  1250.       
  1251.       
  1252.   '    adochild.MoveNext
  1253.  ' Wend
  1254.   
  1255.   '更新子表
  1256.   adochild.UpdateBatch adAffectAllChapters
  1257.   adochild.Close
  1258.   Set adochild = Nothing
  1259.   
  1260.  ' strTemp = txtFields(0).Text
  1261.  ' Set grdDataGrid.DataSource = Nothing
  1262.   'adoPrimaryRS.Requery
  1263.   'adoPrimaryRS.Find "目的港='" & strTemp & "'", 0, adSearchForward
  1264.   'Set grdDataGrid.DataSource = adoPrimaryRS("ChildCMD").UnderlyingValue
  1265.  
  1266.   UpdateData = True
  1267.   
  1268.   If mbAddNewFlag Then
  1269.     adoPrimaryRS.MoveLast              'move to the new record
  1270.   End If
  1271.   mbEditFlag = False
  1272.   mbAddNewFlag = False
  1273.   SetButtons True
  1274.   
  1275.   Exit Function
  1276. UpdateErr:
  1277.   UpdateData = False
  1278. End Function
  1279. Private Sub DTPicker1_KeyPress(KeyAscii As Integer)
  1280.     If KeyAscii = vbKeyReturn Then
  1281.         SendKeys "{TAB}"
  1282.     End If
  1283. End Sub
  1284. Private Sub DTPicker2_KeyPress(KeyAscii As Integer)
  1285. If KeyAscii = vbKeyReturn Then
  1286.     SendKeys "{TAB}"
  1287. End If
  1288. End Sub
  1289. Private Sub DTPicker3_KeyPress(KeyAscii As Integer)
  1290. If KeyAscii = vbKeyReturn Then
  1291.     SendKeys "{TAB}"
  1292. End If
  1293. End Sub
  1294. Private Sub DTPicker4_KeyPress(KeyAscii As Integer)
  1295. If KeyAscii = vbKeyReturn Then
  1296.     SendKeys "{TAB}"
  1297. End If
  1298. End Sub
  1299. Private Sub DTPicker5_KeyPress(KeyAscii As Integer)
  1300. If KeyAscii = vbKeyReturn Then
  1301.     SendKeys "{TAB}"
  1302. End If
  1303. End Sub
  1304. Private Sub DTPicker6_KeyPress(KeyAscii As Integer)
  1305.    If KeyAscii = vbKeyReturn Then
  1306.     SendKeys "{TAB}"
  1307. End If
  1308. End Sub
  1309. Private Sub Form_Load()
  1310. On Error Resume Next
  1311.     For Each TextBox In Me.Controls
  1312.         TextBox.Font.Name = "宋体"
  1313.         TextBox.Font.Size = 9
  1314.     Next
  1315.   Set adoPrimaryRS = New Recordset
  1316.   adoPrimaryRS.Open "SHAPE {select 培训计划编号,实施计划编号,时间,部门,项目名称,培训种类,培训对象,参加人数,举办日期,地点,培训时数,师资来源,培训目的,课时费,租用费,招待费,交通费,教材费,工时占用费用,其他费用,预算费用合计,培训内容,口试,笔试,实际操作,人力资源部经理签字,人力资源部签字时间,财务部经理签字,财务部签字时间,总经理签字,总经理签字时间,部门申请人签字,部门申请人签字时间 from 培训实施计划表} AS ParentCMD APPEND ({select 培训实施计划编号,员工号,姓名,岗位 from 培训实施计划人员 } AS ChildCMD RELATE 实施计划编号 TO 培训实施计划编号) AS ChildCMD", db1, adOpenStatic, adLockBatchOptimistic
  1317.   If adoPrimaryRS.RecordCount <> 0 Then
  1318.       Set DataGrid2.DataSource = adoPrimaryRS
  1319.  End If
  1320.  SetButtons True
  1321.  
  1322.  Set DTPicker1.DataSource = adoPrimaryRS
  1323.  Set DTPicker2.DataSource = adoPrimaryRS
  1324.  Set DTPicker3.DataSource = adoPrimaryRS
  1325.  Set DTPicker4.DataSource = adoPrimaryRS
  1326.  Set DTPicker5.DataSource = adoPrimaryRS
  1327.  Set DTPicker6.DataSource = adoPrimaryRS
  1328.        
  1329.  Set Check1.DataSource = adoPrimaryRS
  1330.  Set Check2.DataSource = adoPrimaryRS
  1331.  Set Check3.DataSource = adoPrimaryRS
  1332.  
  1333.   Dim oText As TextBox
  1334.   'Bind the text boxes to the data provider
  1335.   For Each oText In Me.txtFields
  1336.     Set oText.DataSource = adoPrimaryRS
  1337.   Next
  1338.  
  1339. If adoPrimaryRS.RecordCount <> 0 Then
  1340.        Set DataGrid1.DataSource = adoPrimaryRS("ChildCMD").UnderlyingValue
  1341. End If
  1342. Me.DTPicker1.Value = Format(Now, "yyyy年mm月dd日")
  1343. Me.DTPicker2.Value = Format(Now, "yyyy年mm月dd日")
  1344. Me.DTPicker3.Value = Format(Now, "yyyy年mm月dd日")
  1345. Me.DTPicker4.Value = Format(Now, "yyyy年mm月dd日")
  1346. Me.DTPicker5.Value = Format(Now, "yyyy年mm月dd日")
  1347. Me.DTPicker6.Value = Format(Now, "yyyy年mm月dd日")
  1348. End Sub
  1349. Private Sub Form_Unload(Cancel As Integer)
  1350.   Screen.MousePointer = vbDefault
  1351. End Sub
  1352. Private Sub cmdadd_Click()
  1353.   On Error GoTo AddErr
  1354.   With adoPrimaryRS
  1355.     If Not (.BOF And .EOF) Then
  1356.       mvBookMark = .Bookmark
  1357.     End If
  1358.     .AddNew
  1359.     mbAddNewFlag = True
  1360.     SetButtons False
  1361.   End With
  1362.   On Error GoTo 0
  1363.   Exit Sub
  1364. AddErr:
  1365.   MsgBox "增加操作有错误", vbExclamation + vbOKOnly, pTitle
  1366.   
  1367. End Sub
  1368. Private Sub cmddelete_Click()
  1369.   Dim adochild As ADODB.Recordset
  1370.   On Error GoTo DeleteErr
  1371.   RESULT = MsgBox("此操作将删除此记录所有信息,你真的要删除吗?", vbExclamation + vbYesNo + vbDefaultButton2, "提示")
  1372.   If RESULT = 6 Then                                    '选择YES
  1373.   
  1374.         '删除子表记录
  1375.         
  1376.        Set adochild = New Recordset
  1377.        Set adochild = adoPrimaryRS("ChildCMD").UnderlyingValue
  1378.        While Not adochild.EOF
  1379.             adochild.Delete
  1380.             adochild.MoveNext
  1381.        Wend
  1382.        adochild.UpdateBatch adAffectAll
  1383.        adochild.Close
  1384.        Set adochild = Nothing
  1385.        
  1386.        '删除父表的当前记录
  1387.        
  1388.        With adoPrimaryRS
  1389.          .Delete
  1390.          .UpdateBatch adAffectCurrent
  1391.          .MoveNext
  1392.          If .EOF Then .MoveLast
  1393.        End With
  1394.   End If
  1395.   On Error GoTo 0
  1396.   Exit Sub
  1397.  
  1398. DeleteErr:
  1399.   MsgBox "删除数据失败!", vbExclamation + vbOKOnly, "Ptitle"
  1400. End Sub
  1401. Private Sub cmdRefresh_Click()
  1402.   'This is only needed for multi user apps
  1403.   On Error GoTo RefreshErr
  1404.   adoPrimaryRS.Requery
  1405.   On Error GoTo 0
  1406.   Exit Sub
  1407. RefreshErr:
  1408.    MsgBox "刷新操作有错误", vbExclamation + vbOKOnly, pTitle
  1409. End Sub
  1410. Private Sub cmdedit_Click()
  1411.   On Error GoTo EditErr
  1412.   mbEditFlag = True
  1413.   SetButtons False
  1414.   Exit Sub
  1415.   On Error GoTo 0
  1416. EditErr:
  1417.    MsgBox "更改操作有错误", vbExclamation + vbOKOnly, pTitle
  1418. End Sub
  1419. Private Sub cmdCancel_Click()
  1420.  ' On Error Resume Next
  1421.  On Error GoTo CancelErr
  1422.   mbEditFlag = False
  1423.   mbAddNewFlag = False
  1424.   adoPrimaryRS.CancelUpdate
  1425.   If mvBookMark > 0 Then
  1426.    adoPrimaryRS.Bookmark = mvBookMark
  1427.   Else
  1428.    adoPrimaryRS.MoveFirst
  1429.   End If
  1430.  SetButtons True
  1431.   Exit Sub
  1432. CancelErr:
  1433.    
  1434.    MsgBox "取消操作有错误", vbExclamation + vbOKOnly, pTitle
  1435. End Sub
  1436. Private Sub cmdUpdate_Click()
  1437.   Dim blnUpdateFlag As Boolean
  1438.   blnUpdateFlag = UpdateData
  1439.   If blnUpdateFlag = True Then
  1440.     MsgBox "数据保存成功!", vbInformation + vbOKOnly, "提示"
  1441.   Else
  1442.     MsgBox "数据保存失败!", vbExclamation + vbOKOnly, "警告"
  1443.   End If
  1444. End Sub
  1445. Private Sub cmdClose_Click()
  1446.     RSGL.Enabled = True
  1447.     Unload Me
  1448. End Sub
  1449. Private Sub SetButtons(bVal As Boolean)
  1450. Dim oText As TextBox
  1451.   
  1452.   CmdAdd.Visible = bVal
  1453.   cmdEdit.Visible = bVal
  1454.   cmdUpdate.Visible = Not bVal
  1455.   cmdCancel.Visible = Not bVal
  1456.   CmdDelete.Visible = bVal
  1457.   cmdClose.Visible = bVal
  1458.   cmdRefresh.Visible = bVal
  1459.   
  1460.  
  1461.   For Each oText In Me.txtFields
  1462.         oText.Enabled = Not bVal
  1463.   Next
  1464.   
  1465.   DTPicker1.Enabled = Not bVal
  1466.   DTPicker2.Enabled = Not bVal
  1467.   DTPicker3.Enabled = Not bVal
  1468.   DTPicker4.Enabled = Not bVal
  1469.   DTPicker5.Enabled = Not bVal
  1470.   DTPicker6.Enabled = Not bVal
  1471.   
  1472.   Check1.Enabled = Not bVal
  1473.   Check2.Enabled = Not bVal
  1474.   Check3.Enabled = Not bVal
  1475.   
  1476.   If bVal Then
  1477.    Set DataGrid2.DataSource = adoPrimaryRS
  1478.   Else
  1479.    Set DataGrid2.DataSource = Nothing
  1480.   End If
  1481.   
  1482.   If Not bVal Then
  1483.     If mbEditFlag Then
  1484.      DataGrid1.AllowAddNew = True
  1485.      DataGrid1.AllowDelete = True
  1486.      DataGrid1.AllowUpdate = True
  1487.     End If
  1488.   Else
  1489.      DataGrid1.AllowAddNew = False
  1490.      DataGrid1.AllowDelete = False
  1491.      DataGrid1.AllowUpdate = False
  1492.   End If
  1493. End Sub
  1494. Private Sub grdDataGrid_Error(ByVal DataError As Integer, Response As Integer)
  1495. Response = 0
  1496.     MsgBox "输入数据不合法,请输入合法数据!", vbExclamation + vbOKOnly, pTitle
  1497. End Sub
  1498. Private Sub txtFields_Change(Index As Integer)
  1499.   If IsNumeric(txtFields(18).Text) And IsNumeric(txtFields(19).Text) And IsNumeric(txtFields(13).Text) And IsNumeric(txtFields(14).Text) And IsNumeric(txtFields(15).Text) And IsNumeric(txtFields(16).Text) And IsNumeric(txtFields(17).Text) Then
  1500.    txtFields(20) = CDbl(txtFields(18)) + CDbl(txtFields(19)) + CDbl(txtFields(13)) + CDbl(txtFields(14)) + CDbl(txtFields(15)) + CDbl(txtFields(16)) + CDbl(txtFields(17))
  1501.   End If
  1502.   
  1503. End Sub
  1504. Private Sub txtFields_KeyPress(Index As Integer, KeyAscii As Integer)
  1505. If KeyAscii = vbKeyReturn Then
  1506.     SendKeys "{TAB}"
  1507. End If
  1508. End Sub
  1509. Private Sub txtFields_LostFocus(Index As Integer)
  1510. Select Case Index
  1511. Case 8
  1512.     If Not IsNull(Trim(txtFields(8).Text)) Then
  1513.        '   txtFields(8).Locked = True
  1514.     End If
  1515.     
  1516.     
  1517. Case 0
  1518. Dim Sql3 As String
  1519.  Sql3 = "select 时间,项目名称,培训种类,培训对象,参加人数,举办日期,地点,培训时数,师资来源,培训目的,课时费,租用费,招待费,交通费,教材费,工时占用费,其他费用,预算费用合计,培训内容,口试,笔试,实际操作 from 部门培训计划登记 where 培训计划编号 = '" & txtFields(0).Text & "'"
  1520.  Set rs3 = db.Execute(Sql3)
  1521.  If Not rs3.EOF Then
  1522.    
  1523.  
  1524.    If Not IsNull(rs3("项目名称")) Then
  1525.        txtFields(3).Text = Trim(rs3("项目名称"))
  1526.    End If
  1527.    
  1528.    If Not IsNull(rs3("培训种类")) Then
  1529.        txtFields(5).Text = Trim(rs3("培训种类"))
  1530.    End If
  1531.    
  1532.    If Not IsNull(rs3("培训对象")) Then
  1533.        txtFields(6).Text = Trim(rs3("培训对象"))
  1534.    End If
  1535.    
  1536.    If Not IsNull(rs3("举办日期")) Then
  1537.        DTPicker2.Value = Trim(rs3("举办日期"))
  1538.    End If
  1539.    
  1540.    If Not IsNull(rs3("参加人数")) Then
  1541.        txtFields(7).Text = Trim(rs3("参加人数"))
  1542.    End If
  1543.    
  1544.    
  1545.    
  1546.    If Not IsNull(rs3("地点")) Then
  1547.        txtFields(9).Text = Trim(rs3("地点"))
  1548.    End If
  1549.    
  1550.    If Not IsNull(rs3("培训时数")) Then
  1551.        txtFields(10).Text = Trim(rs3("培训时数"))
  1552.    End If
  1553.    
  1554.    If Not IsNull(rs3("师资来源")) Then
  1555.        txtFields(11).Text = Trim(rs3("师资来源"))
  1556.    End If
  1557.    
  1558.    If Not IsNull(rs3("培训目的")) Then
  1559.        txtFields(1).Text = Trim(rs3("培训目的"))
  1560.    End If
  1561.  
  1562.    If Not IsNull(rs3("课时费")) Then
  1563.      txtFields(13).Text = Trim(rs3("课时费"))
  1564.    End If
  1565.    
  1566.    If Not IsNull(rs3("租用费")) Then
  1567.      txtFields(14).Text = Trim(rs3("租用费"))
  1568.    End If
  1569.    
  1570.    If Not IsNull(rs3("招待费")) Then
  1571.      txtFields(15).Text = Trim(rs3("招待费"))
  1572.    End If
  1573.    
  1574.    If Not IsNull(rs3("交通费")) Then
  1575.      txtFields(16).Text = Trim(rs3("交通费"))
  1576.    End If
  1577.    
  1578.    If Not IsNull(rs3("教材费")) Then
  1579.      txtFields(17).Text = Trim(rs3("教材费"))
  1580.    End If
  1581.    
  1582.    If Not IsNull(rs3("工时占用费")) Then
  1583.      txtFields(18).Text = Trim(rs3("工时占用费"))
  1584.    End If
  1585.    
  1586.    If Not IsNull(rs3("其他费用")) Then
  1587.      txtFields(19).Text = Trim(rs3("其他费用"))
  1588.    End If
  1589.    
  1590.    If Not IsNull(rs3("预算费用合计")) Then
  1591.      txtFields(20).Text = Trim(rs3("预算费用合计"))
  1592.    End If
  1593.    
  1594.     If Not IsNull(rs3("培训内容")) Then
  1595.      txtFields(4).Text = Trim(rs3("培训内容"))
  1596.    End If
  1597.    
  1598.    If Not IsNull(rs3("口试")) And rs3("口试") = True Then
  1599.      Check1.Value = 1
  1600.     Else
  1601.       Check1.Value = 0
  1602.    End If
  1603.    
  1604.    If Not IsNull(rs3("笔试")) And rs3("笔试") = True Then
  1605.      Check2.Value = 1
  1606.     Else
  1607.       Check2.Value = 0
  1608.    End If
  1609.    
  1610.    If Not IsNull(rs3("实际操作")) And rs3("实际操作") = True Then
  1611.      Check3.Value = 1
  1612.     Else
  1613.       Check3.Value = 0
  1614.    End If
  1615.    
  1616. End If
  1617. Case 5
  1618. If Not IsNumeric(txtFields(7).Text) And (txtFields(7).Text <> "") Then
  1619.     MsgBox "请在“参加人数”中输入数字", vbExclamation + vbOKOnly, pTitle
  1620.      txtFields(7).SetFocus
  1621.      txtFields(7).SelStart = 0
  1622.      txtFields(7).SelLength = Len(txtFields(7))
  1623.   
  1624. End If
  1625. Case 10
  1626. If Not IsNumeric(txtFields(10).Text) And (txtFields(10).Text <> "") Then
  1627.     MsgBox "请在“培训时数”中输入数字", vbExclamation + vbOKOnly, pTitle
  1628.      txtFields(10).SetFocus
  1629.      txtFields(10).SelStart = 0
  1630.      txtFields(10).SelLength = Len(txtFields(10))
  1631.      
  1632. End If
  1633. Case 13
  1634. If Not IsNumeric(txtFields(13).Text) And (txtFields(13).Text <> "") Then
  1635.     MsgBox "请在“课时费”中输入数字", vbExclamation + vbOKOnly, pTitle
  1636.      txtFields(13).SetFocus
  1637.      txtFields(13).SelStart = 0
  1638.      txtFields(13).SelLength = Len(txtFields(13))
  1639.      
  1640. End If
  1641. Case 14
  1642. If Not IsNumeric(txtFields(14).Text) And (txtFields(14).Text <> "") Then
  1643.     MsgBox "请在“租用费”中输入数字", vbExclamation + vbOKOnly, pTitle
  1644.      txtFields(14).SetFocus
  1645.      txtFields(14).SelStart = 0
  1646.      txtFields(14).SelLength = Len(txtFields(14))
  1647.      
  1648. End If
  1649. Case 15
  1650. If Not IsNumeric(txtFields(15).Text) And (txtFields(15).Text <> "") Then
  1651.     MsgBox "请在“招待费”中输入数字", vbExclamation + vbOKOnly, pTitle
  1652.      txtFields(15).SetFocus
  1653.      txtFields(15).SelStart = 0
  1654.      txtFields(15).SelLength = Len(txtFields(15))
  1655.      
  1656. End If
  1657. Case 16
  1658. If Not IsNumeric(txtFields(16).Text) And (txtFields(16).Text <> "") Then
  1659.     MsgBox "请在“交通费”中输入数字", vbExclamation + vbOKOnly, pTitle
  1660.      txtFields(16).SetFocus
  1661.      txtFields(16).SelStart = 0
  1662.      txtFields(16).SelLength = Len(txtFields(16))
  1663.      
  1664. End If
  1665. Case 17
  1666. If Not IsNumeric(txtFields(17).Text) And (txtFields(17).Text <> "") Then
  1667.     MsgBox "请在“教材费”中输入数字", vbExclamation + vbOKOnly, pTitle
  1668.      txtFields(17).SetFocus
  1669.       txtFields(17).SelStart = 0
  1670.      txtFields(17).SelLength = Len(txtFields(17))
  1671.     
  1672. End If
  1673. Case 18
  1674. If Not IsNumeric(txtFields(18).Text) And (txtFields(18).Text <> "") Then
  1675.     MsgBox "请在“工时占用费”中输入数字", vbExclamation + vbOKOnly, pTitle
  1676.      txtFields(18).SetFocus
  1677.      txtFields(18).SelStart = 0
  1678.      txtFields(18).SelLength = Len(txtFields(18))
  1679.      
  1680. End If
  1681. Case 19
  1682. If Not IsNumeric(txtFields(19).Text) And (txtFields(19).Text <> "") Then
  1683.     MsgBox "请在“其他费用”中输入数字", vbExclamation + vbOKOnly, pTitle
  1684.      txtFields(19).SetFocus
  1685.      txtFields(19).SelStart = 0
  1686.      txtFields(19).SelLength = Len(txtFields(19))
  1687.      
  1688. End If
  1689. End Select
  1690. txtFields(8).Locked = True
  1691. End Sub