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

企业管理

开发平台:

Visual Basic

  1. VERSION 5.00
  2. Object = "{67397AA1-7FB1-11D0-B148-00A0C922E820}#6.0#0"; "MSADODC.OCX"
  3. Begin VB.Form main_gzgl_gzgl_lr 
  4.    BorderStyle     =   3  'Fixed Dialog
  5.    Caption         =   "工资信息修改"
  6.    ClientHeight    =   3375
  7.    ClientLeft      =   45
  8.    ClientTop       =   330
  9.    ClientWidth     =   9435
  10.    Icon            =   "main_gzgl_gzgl_lr.frx":0000
  11.    LinkTopic       =   "Form1"
  12.    MaxButton       =   0   'False
  13.    MinButton       =   0   'False
  14.    ScaleHeight     =   3375
  15.    ScaleWidth      =   9435
  16.    ShowInTaskbar   =   0   'False
  17.    StartUpPosition =   2  '屏幕中心
  18.    Begin VB.CommandButton Command3 
  19.       Caption         =   "计算"
  20.       Height          =   390
  21.       Left            =   1650
  22.       TabIndex        =   37
  23.       Top             =   2820
  24.       Width           =   1950
  25.    End
  26.    Begin VB.CommandButton Command2 
  27.       Caption         =   "取消"
  28.       Height          =   390
  29.       Left            =   5895
  30.       TabIndex        =   36
  31.       Top             =   2820
  32.       Width           =   1950
  33.    End
  34.    Begin VB.CommandButton Command1 
  35.       Caption         =   "确定"
  36.       Height          =   390
  37.       Left            =   3780
  38.       TabIndex        =   35
  39.       Top             =   2820
  40.       Width           =   1950
  41.    End
  42.    Begin VB.Frame Frame1 
  43.       Height          =   2730
  44.       Left            =   15
  45.       TabIndex        =   0
  46.       Top             =   -45
  47.       Width           =   9420
  48.       Begin VB.TextBox Text1 
  49.          Enabled         =   0   'False
  50.          Height          =   330
  51.          Index           =   16
  52.          Left            =   4380
  53.          Locked          =   -1  'True
  54.          TabIndex        =   32
  55.          Top             =   2175
  56.          Width           =   1845
  57.       End
  58.       Begin VB.TextBox Text1 
  59.          Enabled         =   0   'False
  60.          Height          =   330
  61.          Index           =   15
  62.          Left            =   1425
  63.          TabIndex        =   30
  64.          Top             =   2175
  65.          Width           =   1845
  66.       End
  67.       Begin VB.TextBox Text1 
  68.          Enabled         =   0   'False
  69.          Height          =   330
  70.          Index           =   14
  71.          Left            =   7365
  72.          TabIndex        =   29
  73.          Top             =   1785
  74.          Width           =   1845
  75.       End
  76.       Begin VB.TextBox Text1 
  77.          Height          =   330
  78.          Index           =   13
  79.          Left            =   4380
  80.          TabIndex        =   27
  81.          Top             =   1785
  82.          Width           =   1845
  83.       End
  84.       Begin VB.TextBox Text1 
  85.          Height          =   330
  86.          Index           =   12
  87.          Left            =   1425
  88.          TabIndex        =   25
  89.          Top             =   1785
  90.          Width           =   1845
  91.       End
  92.       Begin VB.TextBox Text1 
  93.          Height          =   330
  94.          Index           =   11
  95.          Left            =   7365
  96.          TabIndex        =   23
  97.          Top             =   1410
  98.          Width           =   1845
  99.       End
  100.       Begin VB.TextBox Text1 
  101.          Height          =   330
  102.          Index           =   10
  103.          Left            =   4380
  104.          TabIndex        =   21
  105.          Top             =   1410
  106.          Width           =   1845
  107.       End
  108.       Begin VB.TextBox Text1 
  109.          Height          =   330
  110.          Index           =   9
  111.          Left            =   1425
  112.          TabIndex        =   19
  113.          Top             =   1410
  114.          Width           =   1845
  115.       End
  116.       Begin VB.TextBox Text1 
  117.          Height          =   330
  118.          Index           =   8
  119.          Left            =   7365
  120.          TabIndex        =   18
  121.          Top             =   1035
  122.          Width           =   1845
  123.       End
  124.       Begin VB.TextBox Text1 
  125.          Height          =   330
  126.          Index           =   7
  127.          Left            =   4380
  128.          TabIndex        =   16
  129.          Top             =   1035
  130.          Width           =   1845
  131.       End
  132.       Begin VB.TextBox Text1 
  133.          Height          =   330
  134.          Index           =   6
  135.          Left            =   1425
  136.          TabIndex        =   14
  137.          Top             =   1035
  138.          Width           =   1845
  139.       End
  140.       Begin VB.TextBox Text1 
  141.          Height          =   330
  142.          Index           =   5
  143.          Left            =   7365
  144.          TabIndex        =   12
  145.          Top             =   660
  146.          Width           =   1845
  147.       End
  148.       Begin VB.TextBox Text1 
  149.          Height          =   330
  150.          Index           =   4
  151.          Left            =   4380
  152.          TabIndex        =   10
  153.          Top             =   660
  154.          Width           =   1845
  155.       End
  156.       Begin VB.TextBox Text1 
  157.          Height          =   330
  158.          Index           =   3
  159.          Left            =   1425
  160.          TabIndex        =   8
  161.          Top             =   660
  162.          Width           =   1845
  163.       End
  164.       Begin VB.TextBox Text1 
  165.          Enabled         =   0   'False
  166.          Height          =   330
  167.          Index           =   2
  168.          Left            =   7365
  169.          TabIndex        =   6
  170.          Top             =   285
  171.          Width           =   1845
  172.       End
  173.       Begin VB.TextBox Text1 
  174.          Enabled         =   0   'False
  175.          Height          =   330
  176.          Index           =   1
  177.          Left            =   4380
  178.          TabIndex        =   4
  179.          Top             =   285
  180.          Width           =   1845
  181.       End
  182.       Begin VB.TextBox Text1 
  183.          Height          =   330
  184.          Index           =   0
  185.          Left            =   1425
  186.          Locked          =   -1  'True
  187.          TabIndex        =   2
  188.          Top             =   285
  189.          Width           =   1845
  190.       End
  191.       Begin VB.Label Label1 
  192.          Caption         =   "实发工资:"
  193.          Height          =   210
  194.          Index           =   16
  195.          Left            =   3420
  196.          TabIndex        =   34
  197.          Top             =   2265
  198.          Width           =   900
  199.       End
  200.       Begin VB.Label Label1 
  201.          Caption         =   "应扣工资:"
  202.          Height          =   210
  203.          Index           =   15
  204.          Left            =   465
  205.          TabIndex        =   33
  206.          Top             =   2250
  207.          Width           =   1005
  208.       End
  209.       Begin VB.Label Label1 
  210.          Caption         =   "应发工资:"
  211.          Height          =   210
  212.          Index           =   14
  213.          Left            =   6405
  214.          TabIndex        =   31
  215.          Top             =   1875
  216.          Width           =   945
  217.       End
  218.       Begin VB.Label Label1 
  219.          Caption         =   "医疗保险:"
  220.          Height          =   210
  221.          Index           =   13
  222.          Left            =   3420
  223.          TabIndex        =   28
  224.          Top             =   1875
  225.          Width           =   1005
  226.       End
  227.       Begin VB.Label Label1 
  228.          Caption         =   "失业保险:"
  229.          Height          =   210
  230.          Index           =   12
  231.          Left            =   450
  232.          TabIndex        =   26
  233.          Top             =   1860
  234.          Width           =   945
  235.       End
  236.       Begin VB.Label Label1 
  237.          Caption         =   "养老保险:"
  238.          Height          =   210
  239.          Index           =   11
  240.          Left            =   6405
  241.          TabIndex        =   24
  242.          Top             =   1485
  243.          Width           =   915
  244.       End
  245.       Begin VB.Label Label1 
  246.          Caption         =   "惩罚总额:"
  247.          Height          =   210
  248.          Index           =   10
  249.          Left            =   3420
  250.          TabIndex        =   22
  251.          Top             =   1485
  252.          Width           =   1005
  253.       End
  254.       Begin VB.Label Label1 
  255.          Caption         =   "旷工费:"
  256.          Height          =   210
  257.          Index           =   9
  258.          Left            =   630
  259.          TabIndex        =   20
  260.          Top             =   1485
  261.          Width           =   720
  262.       End
  263.       Begin VB.Label Label1 
  264.          Caption         =   "职务津贴:"
  265.          Height          =   210
  266.          Index           =   8
  267.          Left            =   6405
  268.          TabIndex        =   17
  269.          Top             =   1110
  270.          Width           =   1005
  271.       End
  272.       Begin VB.Label Label1 
  273.          Caption         =   "奖励总额:"
  274.          Height          =   210
  275.          Index           =   7
  276.          Left            =   3420
  277.          TabIndex        =   15
  278.          Top             =   1110
  279.          Width           =   945
  280.       End
  281.       Begin VB.Label Label1 
  282.          Caption         =   "全勤奖:"
  283.          Height          =   210
  284.          Index           =   6
  285.          Left            =   630
  286.          TabIndex        =   13
  287.          Top             =   1140
  288.          Width           =   720
  289.       End
  290.       Begin VB.Label Label1 
  291.          Caption         =   "工龄工资:"
  292.          Height          =   210
  293.          Index           =   5
  294.          Left            =   6405
  295.          TabIndex        =   11
  296.          Top             =   735
  297.          Width           =   1005
  298.       End
  299.       Begin VB.Label Label1 
  300.          Caption         =   "加班费:"
  301.          Height          =   210
  302.          Index           =   4
  303.          Left            =   3585
  304.          TabIndex        =   9
  305.          Top             =   720
  306.          Width           =   735
  307.       End
  308.       Begin VB.Label Label1 
  309.          Caption         =   "基本工资:"
  310.          Height          =   210
  311.          Index           =   3
  312.          Left            =   465
  313.          TabIndex        =   7
  314.          Top             =   735
  315.          Width           =   900
  316.       End
  317.       Begin VB.Label Label1 
  318.          Caption         =   "员工姓名:"
  319.          Height          =   210
  320.          Index           =   2
  321.          Left            =   6405
  322.          TabIndex        =   5
  323.          Top             =   360
  324.          Width           =   1005
  325.       End
  326.       Begin VB.Label Label1 
  327.          Caption         =   "员工编号:"
  328.          Height          =   210
  329.          Index           =   1
  330.          Left            =   3420
  331.          TabIndex        =   3
  332.          Top             =   360
  333.          Width           =   945
  334.       End
  335.       Begin VB.Label Label1 
  336.          Caption         =   "所属工资月份:"
  337.          Height          =   210
  338.          Index           =   0
  339.          Left            =   120
  340.          TabIndex        =   1
  341.          Top             =   345
  342.          Width           =   1305
  343.       End
  344.    End
  345.    Begin MSAdodcLib.Adodc Adodc1 
  346.       Height          =   330
  347.       Left            =   -1575
  348.       Top             =   870
  349.       Visible         =   0   'False
  350.       Width           =   2040
  351.       _ExtentX        =   3598
  352.       _ExtentY        =   582
  353.       ConnectMode     =   0
  354.       CursorLocation  =   3
  355.       IsolationLevel  =   -1
  356.       ConnectionTimeout=   15
  357.       CommandTimeout  =   30
  358.       CursorType      =   3
  359.       LockType        =   3
  360.       CommandType     =   2
  361.       CursorOptions   =   0
  362.       CacheSize       =   50
  363.       MaxRecords      =   0
  364.       BOFAction       =   0
  365.       EOFAction       =   0
  366.       ConnectStringType=   1
  367.       Appearance      =   1
  368.       BackColor       =   -2147483643
  369.       ForeColor       =   -2147483640
  370.       Orientation     =   0
  371.       Enabled         =   -1
  372.       Connect         =   "Provider=SQLOLEDB.1;Persist Security Info=False;User ID=sa;Initial Catalog=db_manpowerinfo"
  373.       OLEDBString     =   "Provider=SQLOLEDB.1;Persist Security Info=False;User ID=sa;Initial Catalog=db_manpowerinfo"
  374.       OLEDBFile       =   ""
  375.       DataSourceName  =   ""
  376.       OtherAttributes =   ""
  377.       UserName        =   ""
  378.       Password        =   ""
  379.       RecordSource    =   "工资表"
  380.       Caption         =   "Adodc1"
  381.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  382.          Name            =   "宋体"
  383.          Size            =   9
  384.          Charset         =   134
  385.          Weight          =   400
  386.          Underline       =   0   'False
  387.          Italic          =   0   'False
  388.          Strikethrough   =   0   'False
  389.       EndProperty
  390.       _Version        =   393216
  391.    End
  392. End
  393. Attribute VB_Name = "main_gzgl_gzgl_lr"
  394. Attribute VB_GlobalNameSpace = False
  395. Attribute VB_Creatable = False
  396. Attribute VB_PredeclaredId = True
  397. Attribute VB_Exposed = False
  398. Private Sub Form_Activate()
  399.   Text1(3).SetFocus
  400. End Sub
  401. Private Sub Form_Load()
  402.   With main_gzgl_gzgl.DataGrid1
  403.      For i = 0 To 16
  404.          Text1(i).text = .Columns(i).CellValue(.Bookmark)
  405.      Next i
  406.   End With
  407. End Sub
  408. Private Sub Text1_GotFocus(Index As Integer)
  409.   Text1(Index).BackColor = &HFFFF00
  410.   Text1(Index).SelStart = 0
  411.   Text1(Index).SelLength = Len(Text1(Index))
  412. End Sub
  413. Private Sub Text1_LostFocus(Index As Integer)
  414.   Text1(Index).BackColor = &H80000005
  415. End Sub
  416. Private Sub Text1_KeyDown(Index As Integer, KeyCode As Integer, Shift As Integer)
  417.   If KeyCode = vbKeyReturn And Index > 2 And Index < 13 Then Text1(Index + 1).SetFocus
  418. End Sub
  419. Private Sub Command1_Click()
  420.   For i = 3 To 16
  421.    Cnn.Execute "update 工资表 set " & Mid(Label1(i), 1, Len(Label1(i)) - 1) & "=" + Text1(i) + " where 所属工资月份='" + Text1(0) + "'and 员工编号='" + Text1(1) + "'"
  422.   Next i
  423.   Cnn.Execute "update 工资表 set 应发工资=基本工资+工龄工资+加班费+全勤奖+奖励总额+职务津贴 where 所属工资月份='" + Text1(0) + "'and 员工编号='" + Text1(1) + "'"
  424.   Cnn.Execute "update 工资表 set 应扣工资=旷工费+惩罚总额+养老保险+失业保险+医疗保险 where 所属工资月份='" + Text1(0) + "'and 员工编号='" + Text1(1) + "'"
  425.   Cnn.Execute "update 工资表 set 实发工资=应发工资-应扣工资 where 所属工资月份='" + Text1(0) + "'and 员工编号='" + Text1(1) + "'"
  426.   main_gzgl_gzgl.Adodc1.Refresh
  427.   Unload Me
  428. End Sub
  429. Private Sub Command3_Click()
  430.   Text1(14) = Val(Text1(3)) + Val(Text1(4)) + Val(Text1(5)) + Val(Text1(6)) + Val(Text1(7)) + Val(Text1(8)) + Val(Text1(9))
  431.   Text1(15) = Val(Text1(10)) + Val(Text1(11)) + Val(Text1(12)) + Val(Text1(13))
  432.   Text1(16) = Val(Text1(14)) - Val(Text1(15))
  433. End Sub
  434. Private Sub Command2_Click()
  435.   Unload Me
  436. End Sub