main_pyxy.frm
上传用户:wd52qq
上传日期:2022-07-24
资源大小:5366k
文件大小:4k
源码类别:

企业管理

开发平台:

Visual Basic

  1. VERSION 5.00
  2. Object = "{86CF1D34-0C5F-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCT2.OCX"
  3. Begin VB.Form main_pyxy 
  4.    BorderStyle     =   3  'Fixed Dialog
  5.    Caption         =   "Form1"
  6.    ClientHeight    =   2445
  7.    ClientLeft      =   45
  8.    ClientTop       =   330
  9.    ClientWidth     =   4680
  10.    Icon            =   "main_pyxy.frx":0000
  11.    LinkTopic       =   "Form1"
  12.    MaxButton       =   0   'False
  13.    MinButton       =   0   'False
  14.    ScaleHeight     =   2445
  15.    ScaleWidth      =   4680
  16.    ShowInTaskbar   =   0   'False
  17.    StartUpPosition =   2  '屏幕中心
  18.    Begin VB.Frame Frame1 
  19.       Height          =   1785
  20.       Left            =   0
  21.       TabIndex        =   2
  22.       Top             =   0
  23.       Width           =   4635
  24.       Begin VB.TextBox Text1 
  25.          Height          =   330
  26.          Left            =   1515
  27.          TabIndex        =   3
  28.          Top             =   1320
  29.          Width           =   2640
  30.       End
  31.       Begin MSComCtl2.DTPicker DTP1 
  32.          Height          =   345
  33.          Left            =   1830
  34.          TabIndex        =   4
  35.          Top             =   240
  36.          Width           =   2640
  37.          _ExtentX        =   4657
  38.          _ExtentY        =   609
  39.          _Version        =   393216
  40.          Format          =   48168961
  41.          CurrentDate     =   39794
  42.       End
  43.       Begin MSComCtl2.DTPicker DTP2 
  44.          Height          =   345
  45.          Left            =   1830
  46.          TabIndex        =   5
  47.          Top             =   705
  48.          Width           =   2640
  49.          _ExtentX        =   4657
  50.          _ExtentY        =   609
  51.          _Version        =   393216
  52.          Format          =   48168961
  53.          CurrentDate     =   39794
  54.       End
  55.       Begin VB.Label Label1 
  56.          Caption         =   "聘用续约日期:(从)"
  57.          Height          =   225
  58.          Left            =   120
  59.          TabIndex        =   8
  60.          Top             =   330
  61.          Width           =   2385
  62.       End
  63.       Begin VB.Label Label2 
  64.          Caption         =   "(至)"
  65.          Height          =   195
  66.          Left            =   1380
  67.          TabIndex        =   7
  68.          Top             =   825
  69.          Width           =   360
  70.       End
  71.       Begin VB.Label Label3 
  72.          Caption         =   "聘用期限:                               年"
  73.          Height          =   255
  74.          Left            =   555
  75.          TabIndex        =   6
  76.          Top             =   1395
  77.          Width           =   3960
  78.       End
  79.    End
  80.    Begin VB.CommandButton Command1 
  81.       Caption         =   "确定"
  82.       Height          =   390
  83.       Left            =   810
  84.       TabIndex        =   1
  85.       Top             =   1935
  86.       Width           =   1440
  87.    End
  88.    Begin VB.CommandButton Command2 
  89.       Caption         =   "取消"
  90.       Height          =   390
  91.       Left            =   2400
  92.       TabIndex        =   0
  93.       Top             =   1935
  94.       Width           =   1440
  95.    End
  96. End
  97. Attribute VB_Name = "main_pyxy"
  98. Attribute VB_GlobalNameSpace = False
  99. Attribute VB_Creatable = False
  100. Attribute VB_PredeclaredId = True
  101. Attribute VB_Exposed = False
  102. Private Sub Form_Load()
  103.   DTP1.Value = Date
  104.   DTP2.Value = Date
  105. End Sub
  106. Private Sub DTP1_Change()
  107.   Text1 = DateDiff("yyyy", DTP1.Value, DTP2.Value)
  108. End Sub
  109. Private Sub DTP2_Change()
  110.  Text1 = DateDiff("yyyy", DTP1.Value, DTP2.Value)
  111. End Sub
  112. Private Sub Command1_Click()
  113.   Cnn.Execute ("update 聘用表 set 聘用开始日期='" + str(DTP1.Value) + "',聘用结束日期='" + str(DTP2.Value) + "',聘用期限=" + Text1 + ",状态='生效'where 聘用编号='" + main_rsgl_pygl.DataGrid1.Columns(2) + "'")
  114.   main_rsgl_pygl.Adodc1.Refresh
  115.   Unload Me
  116. End Sub
  117. Private Sub Command2_Click()
  118.   Unload Me
  119. End Sub