毕业论文论文范文课程设计实践报告法律论文英语论文教学论文医学论文农学论文艺术论文行政论文管理论文计算机安全
您现在的位置: 毕业论文 >> 论文 >> 正文

VB宾馆管理系统 第9页

更新时间:2009-4-12:  来源:毕业论文

VB宾馆管理系统 第9页
bookin where ammount = '0' and " & sQSql
        frmBookin.Show
    End If
    Me.Hide
End Sub

Private Sub Form_Load()
   
   
    Dim i As Integer
    Dim j As Integer
    Dim sSql As String
    Dim txtSQL As String
    Dim MsgText As String
    Dim mrc As ADODB.Recordset
   
 
    txtSQL = "select distinct datepart(yy,indate) from bookin where ammount = '0' "
    Set mrc = ExecuteSQL(txtSQL, MsgText)
    If mrc.EOF = False Then
        With mrc
751com.cn
boYear(0).ListIndex = 0
       
        For j = 1 To 12
            cboMonth(0).AddItem j
        Next j
        cboMonth(0).Text = Month(Now())
       
        For j = 1 To 31
            cboDay.AddItem j
        Next j
        cboDay.Text = Day(Now())
       
    Else
        cmdOk.Enabled = False
    End If
    mrc.Close
End Sub

Private Sub lblitem_Click(Index As Integer)
    chkItem(Index).Value = vbChecked
   
End Sub

Private Sub txtItem_GotFocus(Index As Integer)
  
    txtItem(Index).SelStart = 0
    txtItem(Index).SelLength = Len(txtItem(Index))
End Sub
3:订房信息列表窗体源代码:
Option Explicit
Public txtSQL As String
Dim mrc As ADODB.Recordset
Dim MsgText As String

 

Private Sub Form_Load()
   
    ShowTitle
    ShowData
    flagBedit = True
End Sub

Private Sub Form_Resize()
    If Me.WindowState <> vbMinimized And fMainForm.WindowState <> vbMinimized Then
        '边界处理
        If Me.ScaleHeight < 10 * lblTitle.Height Then
           
            Exit Sub
        End If
        If Me.ScaleWidth < lblTitle.Width + lblTitle.Width / 2 Then
           
            Exit Sub
        End If
        '控制控件的位置
               
        lblTitle.Top = lblTitle.Height
        lblTitle.Left = (Me.Width - lblTitle.Width) / 2
       
        msgList.Top = lblTitle.Top + lblTitle.Height + lblTitle.Height / 2
        msgList.Width = Me.ScaleWidth - 200
        msgList.Left = Me.ScaleLeft + 100
        msgList.Height = Me.ScaleHeight - msgList.Top - 200
    End If
End Sub

 

Public Sub FormClose()
    Unload Me
End Sub

'删除记录
Private Sub Form_Unload(Cancel As Integer)
    flagBedit = False
    gintBmode = 0
End Sub

 

 


'显示Grid的内容

Private Sub ShowData()
   
    Dim j As Integer
    Dim i As Integer

 
    Set mrc = ExecuteSQL(txtSQL, MsgText)
        With msgList
        .Rows = 1
       
        Do While Not mrc.EOF
            .Rows = .Rows + 1
            For i = 1 To mrc.Fields.Count
                Select Case mrc.Fields(i - 1).Type
                    Case adDBDate
    751com.cn
mrc.Fields(i - 1) & ""
                End Select
            Next i
            mrc.MoveNext
        Loop
       
         
    End With
    mrc.Close
   
   
End Sub


'显示Grid表头
Private Sub ShowTitle()
    Dim i As Integer
   
    With msgList
        .Cols = 8
        .TextMatrix(0, 1) = ""
        .TextMatrix(0, 2) = "顾客姓名"
        .TextMatrix(0, 3) = "身份证号码"
        .TextMatrix(0, 4) = "房间编号"
        .TextMatrix(0, 5) = "入住日期"
        .TextMatrix(0, 6) = "折扣"
        .TextMatrix(0, 7) = "备注"
       
       
        '固定表头
        .FixedRows = 1
               
        '设置各列的对齐方式
        For i = 0 To 7
            .ColAlignment(i) = 0

上一页  [1] [2] [3] [4] [5] [6] [7] [8] [9] 

VB宾馆管理系统 第9页下载如图片无法显示或论文不完整,请联系qq752018766
设为首页 | 联系站长 | 友情链接 | 网站地图 |

copyright©751com.cn 辣文论文网 严禁转载
如果本毕业论文网损害了您的利益或者侵犯了您的权利,请及时联系,我们一定会及时改正。