www.pudn.com > zytgzgl.rar > frmaresult.frm, change:2004-06-15,size:5848b


VERSION 5.00 
Object = "{67397AA1-7FB1-11D0-B148-00A0C922E820}#6.0#0"; "MSADODC.OCX" 
Object = "{CDE57A40-8B86-11D0-B3C6-00A0C90AEA82}#1.0#0"; "MSDATGRD.OCX" 
Begin VB.Form frmaresult  
   Caption         =   "员工出勤结果" 
   ClientHeight    =   6660 
   ClientLeft      =   60 
   ClientTop       =   450 
   ClientWidth     =   9135 
   ControlBox      =   0   'False 
   LinkTopic       =   "Form2" 
   MDIChild        =   -1  'True 
   ScaleHeight     =   6660 
   ScaleWidth      =   9135 
   WindowState     =   2  'Maximized 
   Begin MSDataGridLib.DataGrid DataGrid1  
      Height          =   4095 
      Left            =   480 
      TabIndex        =   1 
      Top             =   1200 
      Width           =   8175 
      _ExtentX        =   14420 
      _ExtentY        =   7223 
      _Version        =   393216 
      HeadLines       =   1 
      RowHeight       =   18 
      BeginProperty HeadFont {0BE35203-8F91-11CE-9DE3-00AA004BB851}  
         Name            =   "宋体" 
         Size            =   9 
         Charset         =   134 
         Weight          =   400 
         Underline       =   0   'False 
         Italic          =   0   'False 
         Strikethrough   =   0   'False 
      EndProperty 
      BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}  
         Name            =   "楷体_GB2312" 
         Size            =   12 
         Charset         =   134 
         Weight          =   700 
         Underline       =   0   'False 
         Italic          =   0   'False 
         Strikethrough   =   0   'False 
      EndProperty 
      ColumnCount     =   2 
      BeginProperty Column00  
         DataField       =   "" 
         Caption         =   "" 
         BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}  
            Type            =   0 
            Format          =   "" 
            HaveTrueFalseNull=   0 
            FirstDayOfWeek  =   0 
            FirstWeekOfYear =   0 
            LCID            =   2052 
            SubFormatType   =   0 
         EndProperty 
      EndProperty 
      BeginProperty Column01  
         DataField       =   "" 
         Caption         =   "" 
         BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}  
            Type            =   0 
            Format          =   "" 
            HaveTrueFalseNull=   0 
            FirstDayOfWeek  =   0 
            FirstWeekOfYear =   0 
            LCID            =   2052 
            SubFormatType   =   0 
         EndProperty 
      EndProperty 
      SplitCount      =   1 
      BeginProperty Split0  
         BeginProperty Column00  
         EndProperty 
         BeginProperty Column01  
         EndProperty 
      EndProperty 
   End 
   Begin MSAdodcLib.Adodc Adodc1  
      Height          =   375 
      Left            =   2280 
      Top             =   5760 
      Visible         =   0   'False 
      Width           =   4575 
      _ExtentX        =   8070 
      _ExtentY        =   661 
      ConnectMode     =   0 
      CursorLocation  =   3 
      IsolationLevel  =   -1 
      ConnectionTimeout=   15 
      CommandTimeout  =   30 
      CursorType      =   3 
      LockType        =   3 
      CommandType     =   8 
      CursorOptions   =   0 
      CacheSize       =   50 
      MaxRecords      =   0 
      BOFAction       =   0 
      EOFAction       =   0 
      ConnectStringType=   1 
      Appearance      =   1 
      BackColor       =   -2147483643 
      ForeColor       =   -2147483640 
      Orientation     =   0 
      Enabled         =   -1 
      Connect         =   "" 
      OLEDBString     =   "" 
      OLEDBFile       =   "" 
      DataSourceName  =   "" 
      OtherAttributes =   "" 
      UserName        =   "" 
      Password        =   "" 
      RecordSource    =   "" 
      Caption         =   "" 
      BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}  
         Name            =   "宋体" 
         Size            =   9 
         Charset         =   134 
         Weight          =   400 
         Underline       =   0   'False 
         Italic          =   0   'False 
         Strikethrough   =   0   'False 
      EndProperty 
      _Version        =   393216 
   End 
   Begin VB.Label Label1  
      Caption         =   "出勤结果" 
      BeginProperty Font  
         Name            =   "楷体_GB2312" 
         Size            =   12 
         Charset         =   134 
         Weight          =   700 
         Underline       =   0   'False 
         Italic          =   0   'False 
         Strikethrough   =   0   'False 
      EndProperty 
      Height          =   495 
      Left            =   840 
      TabIndex        =   0 
      Top             =   360 
      Width           =   1695 
   End 
End 
Attribute VB_Name = "frmaresult" 
Attribute VB_GlobalNameSpace = False 
Attribute VB_Creatable = False 
Attribute VB_PredeclaredId = True 
Attribute VB_Exposed = False 
Option Explicit 
Private Sub Form_Load() 
  Dim sql As String 
  Dim rs As New ADODB.Recordset 
  Dim sd As String 
  If strusername <> "admin" Then 
  sql = "select sid from stuffinfo where sname='" & strusername & "'" 
  Set rs = getrs(sql, "salary") 
  sd = rs(0) 
  sql = "select * from attendancestatistics where stuffid='" & sd & "'" 
  Me.Adodc1.ConnectionString = "provider=microsoft.jet.oledb.4.0;Data source=" & App.Path & "\salary.mdb" 
  Me.Adodc1.RecordSource = sql 
  Me.Adodc1.Refresh 
  Set Me.DataGrid1.DataSource = Me.Adodc1.Recordset 
  Me.DataGrid1.Refresh 
  Else 
  sql = "select * from attendancestatistics" 
  Me.Adodc1.ConnectionString = "provider=microsoft.jet.oledb.4.0;Data source=" & App.Path & "\salary.mdb" 
  Me.Adodc1.RecordSource = sql 
  Me.Adodc1.Refresh 
  Set Me.DataGrid1.DataSource = Me.Adodc1.Recordset 
  Me.DataGrid1.Refresh 
  End If 
End Sub