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

📄 form53.frm

📁 办公自动化 vb+server2
💻 FRM
📖 第 1 页 / 共 2 页
字号:
VERSION 5.00
Object = "{F9043C88-F6F2-101A-A3C9-08002B2F49FB}#1.2#0"; "COMDLG32.OCX"
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCTL.OCX"
Begin VB.Form Form53 
   BorderStyle     =   0  'None
   Caption         =   "Form53"
   ClientHeight    =   8010
   ClientLeft      =   0
   ClientTop       =   0
   ClientWidth     =   12165
   LinkTopic       =   "Form53"
   Picture         =   "Form53.frx":0000
   ScaleHeight     =   8010
   ScaleWidth      =   12165
   ShowInTaskbar   =   0   'False
   StartUpPosition =   3  '窗口缺省
   Begin VB.Frame Frame1 
      Appearance      =   0  'Flat
      BackColor       =   &H80000005&
      Caption         =   "编辑"
      ForeColor       =   &H00FF0000&
      Height          =   7995
      Left            =   0
      TabIndex        =   0
      Top             =   0
      Width           =   1215
      Begin VB.PictureBox Picture1 
         Appearance      =   0  'Flat
         BackColor       =   &H80000005&
         ForeColor       =   &H80000008&
         Height          =   495
         Left            =   360
         Picture         =   "Form53.frx":2C55
         ScaleHeight     =   465
         ScaleWidth      =   465
         TabIndex        =   5
         Top             =   720
         Width           =   495
      End
      Begin VB.PictureBox Picture2 
         Appearance      =   0  'Flat
         BackColor       =   &H80000005&
         ForeColor       =   &H80000008&
         Height          =   495
         Left            =   360
         Picture         =   "Form53.frx":351F
         ScaleHeight     =   465
         ScaleWidth      =   465
         TabIndex        =   4
         Top             =   1920
         Width           =   495
      End
      Begin VB.PictureBox Picture4 
         Appearance      =   0  'Flat
         BackColor       =   &H80000005&
         ForeColor       =   &H80000008&
         Height          =   495
         Left            =   360
         Picture         =   "Form53.frx":3DE9
         ScaleHeight     =   465
         ScaleWidth      =   465
         TabIndex        =   3
         Top             =   5520
         Width           =   495
      End
      Begin VB.PictureBox Picture3 
         Appearance      =   0  'Flat
         BackColor       =   &H80000005&
         ForeColor       =   &H80000008&
         Height          =   495
         Left            =   360
         Picture         =   "Form53.frx":4286
         ScaleHeight     =   465
         ScaleWidth      =   465
         TabIndex        =   2
         Top             =   3120
         Width           =   495
      End
      Begin VB.PictureBox Picture5 
         Appearance      =   0  'Flat
         BackColor       =   &H80000005&
         ForeColor       =   &H80000008&
         Height          =   495
         Left            =   360
         Picture         =   "Form53.frx":4B50
         ScaleHeight     =   465
         ScaleWidth      =   465
         TabIndex        =   1
         Top             =   4320
         Width           =   495
      End
      Begin VB.Label Label5 
         Appearance      =   0  'Flat
         BackColor       =   &H80000005&
         Caption         =   "删除"
         ForeColor       =   &H00FF0000&
         Height          =   255
         Left            =   480
         TabIndex        =   10
         Top             =   1680
         Width           =   495
      End
      Begin VB.Label Label6 
         Appearance      =   0  'Flat
         BackColor       =   &H80000005&
         Caption         =   "修改"
         ForeColor       =   &H00FF0000&
         Height          =   255
         Left            =   480
         TabIndex        =   9
         Top             =   480
         Width           =   495
      End
      Begin VB.Label Label1 
         Appearance      =   0  'Flat
         BackColor       =   &H80000005&
         Caption         =   "关闭"
         ForeColor       =   &H00FF0000&
         Height          =   255
         Left            =   480
         TabIndex        =   8
         Top             =   5280
         Width           =   495
      End
      Begin VB.Label Label4 
         Appearance      =   0  'Flat
         BackColor       =   &H80000005&
         Caption         =   "保存"
         ForeColor       =   &H00FF0000&
         Height          =   255
         Left            =   465
         TabIndex        =   7
         Top             =   2880
         Width           =   495
      End
      Begin VB.Label Label3 
         Appearance      =   0  'Flat
         BackColor       =   &H80000005&
         Caption         =   "打印"
         ForeColor       =   &H00FF0000&
         Height          =   255
         Left            =   480
         TabIndex        =   6
         Top             =   4080
         Width           =   495
      End
   End
   Begin MSComDlg.CommonDialog CommonDialog1 
      Left            =   10560
      Top             =   600
      _ExtentX        =   847
      _ExtentY        =   847
      _Version        =   393216
   End
   Begin MSComctlLib.ListView ListView1 
      Height          =   7575
      Left            =   1200
      TabIndex        =   12
      Top             =   0
      Width           =   10935
      _ExtentX        =   19288
      _ExtentY        =   13361
      View            =   3
      LabelWrap       =   -1  'True
      HideSelection   =   -1  'True
      Checkboxes      =   -1  'True
      FullRowSelect   =   -1  'True
      GridLines       =   -1  'True
      HotTracking     =   -1  'True
      _Version        =   393217
      ForeColor       =   0
      BackColor       =   16777215
      BorderStyle     =   1
      Appearance      =   0
      NumItems        =   4
      BeginProperty ColumnHeader(1) {BDD1F052-858B-11D1-B16A-00C0F0283628} 
         Text            =   "     工程编号"
         Object.Width           =   7056
      EndProperty
      BeginProperty ColumnHeader(2) {BDD1F052-858B-11D1-B16A-00C0F0283628} 
         Alignment       =   2
         SubItemIndex    =   1
         Text            =   "工程名称"
         Object.Width           =   5292
      EndProperty
      BeginProperty ColumnHeader(3) {BDD1F052-858B-11D1-B16A-00C0F0283628} 
         Alignment       =   2
         SubItemIndex    =   2
         Text            =   "结算员"
         Object.Width           =   3528
      EndProperty
      BeginProperty ColumnHeader(4) {BDD1F052-858B-11D1-B16A-00C0F0283628} 
         Alignment       =   2
         SubItemIndex    =   3
         Text            =   "结算时间"
         Object.Width           =   3353
      EndProperty
      Picture         =   "Form53.frx":541A
   End
   Begin VB.Label Label2 
      Appearance      =   0  'Flat
      BackColor       =   &H80000005&
      BackStyle       =   0  'Transparent
      ForeColor       =   &H00FF0000&
      Height          =   375
      Left            =   1200
      TabIndex        =   11
      Top             =   7680
      Width           =   11175
   End
End
Attribute VB_Name = "Form53"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim normalstring(30) As String
Dim mm As Integer
Dim string1, string2 As String
Option Explicit
Dim rn As ADODB.Connection
Private Sub Form_Load()
   With Me
    .Height = 8010
    .left = 2332
    .top = 2600
    .Width = 12160
End With
End Sub


Private Sub Picture1_Click()
Dim i, m, j, n, k, p, l, d, z, y As Integer
Dim c, MyPos, MyPos1 As Integer
Dim c1, c2, c3, c4, c5, SearchString, SearchChar As String
Dim a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a15, a16, a17, a18, a19, a20, a21, a22, a23, a24, a25, a26, a27, a28, a29, a30, a31, a32, a33, a34, a35, a36, a37, a38, a39, a40, a41, a42, a43, a44, a45, a46, a47, a48, a49, a50, a51, a52, a53, a54, a55, a56, a57, a58, a59, a60, a61, a62, a63, a64, a65, a66, a67, a68, a69, a70, a71, a72, a73, a74, a75, a76, a77, a78, a79, a80, a81, a82, a83, a84, a85, a86, a87, a88, a89, a90, a91, a92, a93, a94, a95, a96, a97, a98, a99, a100, a101, a102, a103, a104, a105, a106, a107, a108, a109, a110, a111, a112, a113, a114, a115, a116, a117, a118, a119, a120, a121, a122, a123, a124, a125, a126, a127, a128, a129, a130, a131
Dim da As Date
da = Date

For i = 1 To Form53.ListView1.ListItems.Count
  If Form53.ListView1.ListItems.Item(i).Checked = True Then
     m = m + 1
  End If
Next
If m <> 1 Then
   MsgBox "修改一条记录!", vbInformation, "提示"
   Exit Sub
End If

l = 0
   hzrs.CursorLocation = adUseClient
   hzrs.Open "select * from 勘察工程任务结算单", hzconn, adOpenKeyset, adLockPessimistic
    For j = 1 To Form53.ListView1.ListItems.Count
     If Form53.ListView1.ListItems.Item(j).Checked = True Then
       For n = 1 To hzrs.RecordCount
        If hzrs.Fields(1).Value = Form53.ListView1.ListItems.Item(j) Then
          If hzrs.Fields(42).Value = username Then
            MyPos1 = 1
          End If
          If hzrs.Fields(44).Value = "0" And hzrs.Fields(46).Value = "0" Then
            MyPos = 1   ' 要查找字符串 "P"。
          End If
          If hzrs.Fields(44).Value <> "0" Or hzrs.Fields(46).Value <> "0" Then
            c1 = hzrs.Fields(45).Value
            c2 = hzrs.Fields(47).Value
            c4 = c1 & c2
            SearchString = c4 ' 被搜索的字符串。
            SearchChar = "改"   ' 要查找字符串 "P"
            MyPos = InStr(1, SearchString, SearchChar, 1)
          End If

        If MyPos <> 0 And MyPos1 <> 0 Then
            For l = 1 To 6
              If hzrs.Fields(l).Value = 0 Then
                Form54.Text1(l).Text = ""
               Else
                Form54.Text1(l).Text = hzrs.Fields(l).Value
              End If
            Next
            For l = 26 To 50
              If hzrs.Fields(l).Value = 0 Then
                 Form54.Text1(l).Text = ""
               Else
                 Form54.Text1(l).Text = hzrs.Fields(l).Value
               End If
            Next
            For l = 51 To 79
              If hzrs.Fields(l).Value = 0 Then
                 Form54.Text1(l + 2).Text = ""
               Else
                 Form54.Text1(l + 2).Text = hzrs.Fields(l).Value
               End If
            Next
           Else
            y = y + 1
          End If
        End If
      hzrs.MoveNext
     Next
  End If
Next
hzrs.Close

If y = 0 Then
   For z = 2 To 6
     Form54.Text1(z).Enabled = True
   Next
   For z = 26 To 41

⌨️ 快捷键说明

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