?? mdiform1.frm
字號:
Caption = "檔案輸入"
End
Begin VB.Menu menu12
Caption = "檔案導入"
End
End
Begin VB.Menu MENU41
Caption = "數據管理"
Begin VB.Menu MENU411
Caption = "表底錄入"
End
Begin VB.Menu MENU412
Caption = "費用轉換"
End
End
Begin VB.Menu menu13
Caption = "收費管理"
Begin VB.Menu MENU132
Caption = "繳費處理"
End
End
Begin VB.Menu MENU2
Caption = "報表查詢"
Begin VB.Menu MENU22
Caption = "月報表查詢"
End
Begin VB.Menu MENU23
Caption = "資金明細"
End
Begin VB.Menu MENU24
Caption = "抄表表單打印"
End
Begin VB.Menu MENU21
Caption = "單戶明細查詢"
End
End
Begin VB.Menu MENU3
Caption = "系統管理"
Begin VB.Menu MENU31
Caption = "系統維護"
End
Begin VB.Menu MENU32
Caption = "權限管理"
End
Begin VB.Menu MENU33
Caption = "退出"
End
End
End
Attribute VB_Name = "MDIForm1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Sub DispTreeViewStatus()
tvList.Style = tvwTreelinesPlusMinusPictureText 'Style 7.
tvList.LineStyle = tvwTreeLines 'LineSsstyle 1.
tvList.ImageList = ImageList2
tvList.Nodes.Clear
Dim MYSET As New ADODB.Recordset
Dim nodx As Node
Dim RTUSet As New ADODB.Recordset
Dim I As Long '創建變量。
Set nodx = tvList.Nodes.Add(, , "Root", "tianwei", 4)
strsql = "select * from LOUHAO"
RTUSet.Open strsql, config.cnZdx, adOpenStatic, adLockReadOnly
Do Until RTUSet.EOF
Set nodx = tvList.Nodes.Add("Root", tvwChild, "R_" & _
Trim(RTUSet("bmid")), Format(Trim(RTUSet("bmid")), "00") & _
" " & RTUSet("bmname"), 11)
nodx.Tag = RTUSet("bmid")
strsql = "select * from user1 where louhaoid='" & RTUSet("bmname") & "'order by userid1"
MYSET.Open strsql, config.cnZdx, adOpenStatic, adLockReadOnly
Do Until MYSET.EOF
'添加所節點
Set nodx = tvList.Nodes.Add("R_" & Trim(RTUSet("bmid")), tvwChild, "P_" _
& MYSET("userid1"), " " _
& Mid(MYSET("huhao"), InStr(1, MYSET("HUHAO"), "-") + 1) & " " & Trim(MYSET("name")), 5)
nodx.Tag = MYSET("userid1")
MYSET.MoveNext
Loop
MYSET.Close
RTUSet.MoveNext
Loop
nodx.Root.EnsureVisible '顯示所有節點
' nodX.Root.Child.EnsureVisible
tvList.Nodes("Root").Expanded = True
tvList.Nodes("Root").Child.Expanded = False
Set tvList.SelectedItem = nodx.Root.Child
End Sub
Private Sub MENU131_Click()
End Sub
Private Sub MENU132_Click()
'Dim myset As New ADODB.Recordset
'strsql = "select * from FEE where clloyear=" & _
Year(Now) & " and cllomonth=" & _
Month(Now)
' myset.Open strsql, config.cnZdx, adOpenStatic, adLockReadOnly
' If myset.EOF Then
' MsgBox "本月表數據未轉換,請運行數據轉換程序", vbOKOnly + vbInformation
'Exit Sub
'End If
frmfeeinput.Show
End Sub
Private Sub menu133_Click()
End Sub
Private Sub MENU22_Click()
frmfee.Show vbModal
End Sub
Private Sub MENU23_Click()
frmfee1.Show
End Sub
Private Sub MENU24_Click()
frmbiao.Show vbModal
End Sub
Private Sub MENU31_Click()
Form1.Show vbModal
End Sub
Private Sub MENU32_Click()
frmpassword.Show vbModal
End Sub
Private Sub MDIForm_Load()
Dim lStyle As Long
lStyle = GetWindowLong(tbList.hwnd, GWL_STYLE)
lStyle = lStyle Or WS_THICKFRAME
SetWindowLong tbList.hwnd, GWL_STYLE, lStyle
Me.Left = GetSetting(App.Title, "Settings", "MainLeft", 1000)
Me.Top = GetSetting(App.Title, "Settings", "MainTop", 1000)
Me.Width = GetSetting(App.Title, "Settings", "MainWidth", 6500)
Me.Height = GetSetting(App.Title, "Settings", "MainHeight", 6500)
Me.WindowState = vbMaximized
frmReal.Show
'Tvlist.Move tblist.Left - 10, tblist.Top - 200, tblist.Width - 20, tblist.Height - 220
DispTreeViewStatus
If SKIP.Option1(0) = True Then
tvList.Enabled = False
End If
End Sub
Private Sub MDIForm_Resize()
On Error Resume Next
If Me.WindowState <> vbMinimized Then
End If
End Sub
Private Sub MENU33_Click()
Unload Me
End Sub
Private Sub MENU411_Click()
frmdatainput.Show
End Sub
Private Sub MENU412_Click()
'Dim MYSET As New ADODB.Recordset
'Dim myset1 As New ADODB.Recordset
'Dim strsql As String
'strsql = "select * from user1 "
'myset1.Open strsql, config.cnZdx, adOpenStatic, adLockReadOnly
'If myset1.EOF Then
'Exit Sub
'End If
' strsql = "select * from datawork where clloyear=" & _
Year(Now) & " and cllomonth=" & _
Month(Now)
' MYSET.Open strsql, config.cnZdx, adOpenStatic, adLockReadOnly
' If MYSET.EOF Then
' MsgBox "本月表數據不存在,請運行表底輸入程序輸入用戶本月表底", vbOKOnly + vbInformation
' Exit Sub
' End If
' If MYSET.RecordCount < myset1.RecordCount Then
' MsgBox "該月表計數據共" & myset1.RecordCount & "戶,請確定表計輸入已全部完成,再執行月費用計算程序", vbOKOnly + vbInformation
' Exit Sub
' End If
Form3.Show
End Sub
Private Sub tbList_Resize()
On Error Resume Next
tvList.Move tbList.Left + 20, tbList.Top - 300, tbList.Width - 180, tbList.Height - 580
End Sub
Private Sub Toolbar1_ButtonClick(ByVal Button As MSComctlLib.Button)
On Error Resume Next
Select Case Button.Key
Case "DANAN"
'應做:添加 'youer' 按鈕代碼。
frmChildInput.Show
Case "mima"
'應做:添加 'mima' 按鈕代碼。
frmpassword.Show vbModal
Case "DAORU"
'應做:添加 'mima' 按鈕代碼。
Form2.Show vbModal
Case "YUE"
frmfee.Show
Case "DANHU"
frmReal.Show
Case "DANHU"
frmfeeinput.Show
Case "幫助"
'應做:添加 '幫助' 按鈕代碼。
Case "Oofl"
'應做:添加 'Oofl' 按鈕代碼。
Unload Me
End Select
End Sub
Private Sub MENU11_Click()
frmChildInput.Show
End Sub
Private Sub MENU12_Click()
Form2.Show vbModal
End Sub
Private Sub Tvlist_NodeClick(ByVal Node As MSComctlLib.Node)
If ActiveForm Is frmChildInput Then
If Mid(Node.Key, 1, 1) = "P" Then
frmChildInput.DISINFORM Mid(Node.Parent.Text, _
InStr(1, Node.Parent.Text, " ") + 1), Mid(Node.Key, InStr(1, Node.Key, "_") + 1)
frmChildInput.DISINFORM1 Year(Date), Month(Date), Mid(Node.Key, InStr(1, Node.Key, "_") + 1)
If frmChildInput.txtfields(0) > 0 Then
frmChildInput.cmdModify.Enabled = True
frmChildInput.cmdDelete.Enabled = True
'On Error Resume Next
End If
End If
ElseIf ActiveForm Is frmfeeinput Then
If Mid(Node.Key, 1, 1) = "P" Then
frmfeeinput.DISINFORM Mid(Node.Parent.Text, _
InStr(1, Node.Parent.Text, " ") + 1), Mid(Node.Key, InStr(1, Node.Key, "_") + 1)
frmfeeinput.DISINFORM2 Mid(Node.Key, 3)
End If
Else
If Mid(Node.Key, 1, 1) = "P" Then
frmReal.disuserdata Mid(Node.Key, 3)
End If
End If
End Sub
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -