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

📄 frmmain.frm

📁 vb编出的关于传销工资结算系统
💻 FRM
📖 第 1 页 / 共 2 页
字号:
   End
   Begin VB.Menu mnuQuery 
      Caption         =   "查询"
      Begin VB.Menu mnuYEJIDANQuery 
         Caption         =   "业务员资料查询"
      End
      Begin VB.Menu mnuSGTJQuery 
         Caption         =   "审购统计查询"
      End
      Begin VB.Menu mnuYGYJQuery 
         Caption         =   "员工业绩查询"
      End
   End
   Begin VB.Menu mnuSettlement 
      Caption         =   "月末结算"
      Begin VB.Menu mnuPaymentDay 
         Caption         =   "月末设置"
      End
      Begin VB.Menu grid10 
         Caption         =   "-"
      End
      Begin VB.Menu mnuMonthPayment 
         Caption         =   "月末结算"
      End
   End
   Begin VB.Menu mnuDataBaseOperate 
      Caption         =   "数据库操作"
      Begin VB.Menu mnuDataBaseClean 
         Caption         =   "数据清理"
      End
      Begin VB.Menu grid9 
         Caption         =   "-"
      End
      Begin VB.Menu mnuDataBaseBackup 
         Caption         =   "数据库备份"
      End
      Begin VB.Menu mnuDataBaseRestor 
         Caption         =   "数据恢复"
      End
   End
   Begin VB.Menu mnuHelp 
      Caption         =   "帮助"
      Begin VB.Menu mnuUseHelp 
         Caption         =   "使用帮助"
      End
      Begin VB.Menu mnuUserRegister 
         Caption         =   "用户注册"
      End
      Begin VB.Menu mnuAbout 
         Caption         =   "关于"
      End
   End
End
Attribute VB_Name = "frmMain"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim ConnRight As New ADODB.Connection
'Dim ConnRightLevel As New ADODB.Connection
Dim rs As New ADODB.Recordset

Private Sub cmdHelp_Click()
   WhatsThisMode
End Sub

Private Sub Form_Load()
  Dim ConnStr As String
  Dim Sql As String
  Dim RightLevel As String
  Dim RightContent As String
  
  PaymentDay = Adodc3.Recordset("结算日期")
  
  '状态栏显示登录用户、登录日期时间及当前系统时间
  StatusBar1.Panels(1).Text = StatusBar1.Panels(1).Text & LoginName
  StatusBar1.Panels(2).Text = StatusBar1.Panels(2).Text & Date & " " & Time
  StatusBar1.Panels(3).Text = StatusBar1.Panels(3).Text & Time
  
  ConnStr = "Provider=Microsoft.Jet.OLEDB.3.51;Data Source=c:\system\database\system.mdb"
  ConnRight.Open ConnStr
  'ConnRightLevel.Open ConnStr
  rs.CursorLocation = adUseClient
    
  Sql = "select * from 权限设置 where 登录名= '" & LoginName & "'"
  rs.Open Sql, ConnRight, adOpenKeyset, adLockPessimistic
  
  With rs
    RightLevel = !权限等级名称
  End With
  
  If rs.State = adStateOpen Then
     rs.Close
  End If
  
  Sql = "select * from 权限等级设置 where 权限等级名称= '" & RightLevel & "'"
  rs.Open Sql, ConnRight, adOpenKeyset, adLockPessimistic
  
  With rs
    RightContent = !等级管理内容
  End With
  
  If Mid(RightContent, 1, 1) = 0 Then
     mnuSystemInitialize.Enabled = False
  End If
  
  If Mid(RightContent, 2, 1) = 0 Then
     mnuRightSetting.Enabled = False
  End If
  
  If Mid(RightContent, 3, 1) = 0 Then
     mnuInviteInitialize.Enabled = False
  End If
  
  If Mid(RightContent, 4, 1) = 0 Then
     mnuDeclare.Enabled = False
  End If
  
  If Mid(RightContent, 5, 1) = 0 Then
     mnuZhaopinRegister.Enabled = False
  End If
  
  If Mid(RightContent, 6, 1) = 0 Then
     mnuEmployeeQuery.Enabled = False
  End If
  
  If Mid(RightContent, 7, 1) = 0 Then
     mnuCommodity.Enabled = False
  End If
  
  If Mid(RightContent, 8, 1) = 0 Then
     mnuSellListing.Enabled = False
  End If
  
  If Mid(RightContent, 9, 1) = 0 Then
     mnuSellBillQuery.Enabled = False
  End If
  
  If Mid(RightContent, 10, 1) = 0 Then
     mnuYEJIDANQuery.Enabled = False
  End If
  
  If Mid(RightContent, 11, 1) = 0 Then
     mnuSGTJQuery.Enabled = False
  End If
  
  If Mid(RightContent, 12, 1) = 0 Then
     mnuYGYJQuery.Enabled = False
  End If
  
  If Mid(RightContent, 13, 1) = 0 Then
     mnuPaymentDay.Enabled = False
  End If
  
  If Mid(RightContent, 14, 1) = 0 Then
     mnuMonthPayment.Enabled = False
  End If
  
  If Mid(RightContent, 15, 1) = 0 Then
     mnuDataBaseClean.Enabled = False
  End If
  
  If Mid(RightContent, 16, 1) = 0 Then
     mnuDataBaseBackup.Enabled = False
  End If
  
  If Mid(RightContent, 17, 1) = 0 Then
     mnuDataBaseRestor.Enabled = False
  End If
  
  If rs.State = adStateOpen Then
     rs.Close
  End If
  
  ConnRight.Close
  
  Set ConnRight = Nothing
End Sub

Private Sub Form_Resize()
  Picture1.Left = 0
  Picture1.Top = Toolbar1.Height
  Picture1.Width = Me.ScaleWidth
  Picture1.Height = Me.ScaleHeight - Toolbar1.Height - StatusBar1.Height
End Sub

Private Sub mnuAbout_Click()
  'frmAbout.Show 1
End Sub

Private Sub mnuCommodity_Click()
  frmCommodity.Show 1
End Sub

Private Sub mnuOperatorAuditing_Click()
  frmOperatorAuditing.Show 1
End Sub

Private Sub mnuCoSetting_Click()
  frmCoSetting.Show 1
End Sub

Private Sub mnuDataBaseBackup_Click()
  frmDataBackup.Show 1
End Sub

Private Sub mnuDataBaseClean_Click()
  frmDataClear.Show 1
End Sub

Private Sub mnuDataBaseRestor_Click()
  Unload Me
  frmDataRestore.Show 1
End Sub

Private Sub mnuDeclare_Click()
  frmDeclare.Show 1
End Sub

Private Sub mnuEmployeeQuery_Click()
  frmEmployeeQuery.Show 1
End Sub

Private Sub mnuInviteInitialize_Click()
  frmInviteInitialize.Show 1
End Sub

Private Sub mnuMonthPayment_Click()
  frmMonthPayment.Show 1
End Sub

Private Sub mnuPaymentDay_Click()
  frmPaymentDay.Show 1
End Sub

Private Sub mnuPayReport_Click()
  frmPayReport.Show 1
End Sub

Private Sub mnuQuit_Click()
  Unload Me
End Sub

Private Sub mnuRightSetting_Click()
  frmRightSetting.Show 1
End Sub

Private Sub mnuSellBillQuery_Click()
  frmSellBillQuery.Show 1
End Sub

Private Sub mnuSellListing_Click()
  frmSellListing.Show 1
End Sub

Private Sub mnuSGTJQuery_Click()
  frmOrderStatistics.Show 1
End Sub

Private Sub mnuSystemInitialize_Click()
  frmSystemInitialize.Show 1
End Sub

Private Sub mnuUseHelp_Click()
  cmdHelp_Click
End Sub

Private Sub mnuYEJIDANQuery_Click()
  frmEmployeeInformation.Show 1
End Sub

Private Sub mnuYGYJQuery_Click()
  frmEmployeeAchievement.Show 1
End Sub

Private Sub mnuZhaopinRegister_Click()
  frmZhaopinRegister.Show 1
End Sub

Private Sub Timer1_Timer()
  StatusBar1.Panels(3).Text = "当前系统时间 " & Time
End Sub

⌨️ 快捷键说明

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