亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? frmcheckin.vb

?? This is a sample of login file in asp pages format
?? VB
字號:
Imports System.Data.OleDb
Public Class frmCheckIn
    Dim Da As New OleDbDataAdapter
    Dim Dt, Dt1, Dt2 As New DataTable
    Dim CID, CRoom As Int16 'Check Condition from tblCheckIn
    Dim BkID, BkRoom As Int16 'Check Conditon from tblBooking

    Private Sub frmCheckIn_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        'OpenConnect()
        cboGender.SendToBack()
        txtCheckIn.Text = Format(Now, "dddd, MMMM dd, yyyy")
        ' Load Data into cboRoomType
        LoadRoomType(cboRType)

        If CName <> "" Then
            cboCusName.Text = CName
            txtCusID.Text = CuID
            txtAddress.Text = CAddress
            txtGender.Text = CGender
            txtPassNo.Text = CPNo
            txtCardNo.Text = CCNo
        End If

        ' Add Icon to Button New
        PIconButton(4)
    End Sub

    Private Sub cboRType_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cboRType.SelectedIndexChanged
        LoadRoomNum(cboRNum, cboRType, txtAmount, txtFloor, txtStaying, txtTotal)
    End Sub

    Private Sub cboRNum_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cboRNum.SelectedIndexChanged
        LoadFloor(cboRNum, txtFloor)
    End Sub
    Sub Clearcus()
        cboCusName.Text = ""
        txtCusID.Clear()
        txtGender.Clear()
        txtAddress.Clear()
        txtPassNo.Clear()
        txtCardNo.Clear()
    End Sub

    Private Sub cboCusName_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles cboCusName.KeyPress
        If Asc(e.KeyChar) = 13 Then
            btnSCustomer_Click(sender, e)
        End If
    End Sub

    Private Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnClose.Click
        Me.Close()
        CuID = ""
        CName = ""
        CGender = ""
        CAddress = ""
        CPNo = ""
        CCNo = ""
    End Sub

    Private Sub txtStaying_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtStaying.TextChanged
        txtCheckOut.Text = Format(DateAdd(DateInterval.Day, Val(txtStaying.Text), CDate(txtCheckIn.Text)), "dddd, MMMM dd, yyyy")
        txtTotal.Text = Val(txtStaying.Text) * Format(txtAmount.Text, "currency")
        txtTotal.Text = Format(txtTotal.Text, "Currency")
    End Sub

    Private Sub txtPrepaid_GotFocus(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtPrepaid.GotFocus
        txtPrepaid.SelectAll()
    End Sub

    Private Sub txtPrepaid_LostFocus(ByVal sender As Object, ByVal e As System.EventArgs) Handles txtPrepaid.LostFocus
        PrepaidLostFocus(txtPrepaid, txtTotal)
    End Sub

    Private Sub txtPrepaid_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtPrepaid.TextChanged
        If txtPrepaid.Text <> "" Then
            txtRemain.Text = Format(txtTotal.Text, "Currency") - Format(txtPrepaid.Text, "Currency")
            txtRemain.Text = Format(txtRemain.Text, "Currency")
        End If
    End Sub

    Private Sub btnCheckIn_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCheckIn.Click
        If cboCusName.Text = "" Then
            Message("Choose one Customer to Check In.")
            cboCusName.Focus()
        ElseIf txtStaying.Text = "" Then
            Message("Complete Number of Staying.")
            txtStaying.Focus()
        ElseIf cboRNum.Text = "" Then
            Message("Choose One Room Number.")
            cboRNum.Focus()
        ElseIf txtPrepaid.Text = "" Then
            Message("Complete Prepaid.")
            txtPrepaid.Focus()
        Else
            CID = Getid("tblCheckIn", "CheckInNo", "CusID='" & txtCusID.Text & "'") - 1
            If CID = 0 Then
                CRoom = Getid("tblCheckIn", "CheckInNo", "RoomNo=" & cboRNum.Text & "") - 1
                If CRoom = 0 Then
                    If i = 1 Then
                        Com.CommandText = "Delete from tblBooking where CusID='" & txtCusID.Text & "'"
                        Com.ExecuteNonQuery()
                        CheckIn()
                    Else
                        BkID = Getid("tblBooking", "ID", "CusID='" & txtCusID.Text & "'") - 1
                        If BkID = 0 Then
                            BkRoom = Getid("tblBooking", "ID", "RoomNo=" & cboRNum.Text & "") - 1
                            If BkRoom = 0 Then
                                CheckIn()
                                i = 0
                            Else
                                Message("Room " & cboRNum.Text & " was Booked already.")
                            End If
                        Else
                            Message("This Customer was Booked already.")
                            cboCusName.Focus()
                            cboCusName.SelectAll()
                        End If
                    End If
                Else
                    Message("Room " & cboRNum.Text & " was not free.")
                    cboRNum.Focus()
                End If
            Else
                Message("This Customers are Staying.")
                cboCusName.Focus()
                cboCusName.SelectAll()
            End If
        End If
    End Sub

    Sub CheckIn()
        Dim CheckID As Integer
        CheckID = Getid("tblCheckIn", "CheckInNo")
        Com.CommandText = "Insert into tblCheckIn Values(?,?,?,?,?,?)"
        With Com.Parameters
            .Add("@ChID", OleDbType.Integer).Value = CheckID
            .Add("@DIn", OleDbType.Date).Value = txtCheckIn.Text
            .Add("@DOut", OleDbType.Date).Value = txtCheckOut.Text
            .Add("@CID", OleDbType.VarChar).Value = txtCusID.Text
            .Add("@RNo", OleDbType.Integer).Value = cboRNum.Text
            .Add("@Prepaid", OleDbType.Currency).Value = txtPrepaid.Text
        End With
        Com.ExecuteNonQuery()
        Com.Parameters.Clear()
        Message("Success.")
        Clearcus()
        txtStaying.Clear()
        txtCheckOut.Clear()
        'txtAmount.Clear()
        txtTotal.Clear()
        txtPrepaid.Clear()
        txtRemain.Clear()
        cboCusName.Focus()
    End Sub

    Sub PIconButton(ByVal Icon As Int16)
        btnNew.ImageList = ImageList1
        btnNew.ImageIndex = Icon
    End Sub

    Private Sub btnNew_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnNew.Click
        If btnNew.Text = "     New" Then
            Clearcus()
            txtAddress.ReadOnly = False
            txtPassNo.ReadOnly = False
            txtGender.SendToBack()
            txtCardNo.ReadOnly = False
            cboCusName.Focus()
            txtCusID.Text = "Cust-" & Format(AutoID("tblCustomer", "CusID"), "0000")
            btnNew.Text = "     Save"
            PIconButton(0)
        Else
            If cboCusName.Text = "" Then
                Message("Complete Customer Name.")
                cboCusName.Focus()
            ElseIf cboGender.Text = "" Then
                Message("Choose One Gender.")
                cboGender.Focus()
            ElseIf txtAddress.Text = "" Then
                Message("Complete Address.")
                txtAddress.Focus()
            ElseIf txtCardNo.Text = "" Then
                Message("Complete Card No.")
                txtCardNo.Focus()
            Else
                Dim Mess As String
                Mess = MsgBox("Do you want to Quick Save?", MsgBoxStyle.OkCancel + MsgBoxStyle.Information, "Hotel Management System")
                If Mess = vbCancel Then
                    CName = cboCusName.Text
                    CGender = cboGender.Text
                    CAddress = txtAddress.Text
                    CPNo = txtPassNo.Text
                    CCNo = txtCardNo.Text
                    Me.Close()
                    Form1.Show()
                Else
                    Com.CommandText = "Insert into tblCustomer Values(?,?,?,?,?,?,?,?,?,?,?)"
                    With Com.Parameters
                        .Add("@CID", OleDbType.VarChar).Value = txtCusID.Text
                        .Add("@CName", OleDbType.VarChar).Value = cboCusName.Text
                        .Add("@Gender", OleDbType.VarChar).Value = cboGender.Text
                        .Add("@DOB", OleDbType.VarChar).Value = " "
                        .Add("@Address", OleDbType.VarChar).Value = txtAddress.Text
                        .Add("@City", OleDbType.VarChar).Value = " "
                        .Add("@State", OleDbType.VarChar).Value = " "
                        .Add("@Country", OleDbType.VarChar).Value = " "
                        .Add("@Nationality", OleDbType.VarChar).Value = " "
                        .Add("@PassNo", OleDbType.VarChar).Value = txtPassNo.Text
                        .Add("@CardNo", OleDbType.VarChar).Value = txtCardNo.Text
                    End With
                    Com.ExecuteNonQuery()
                    Com.Parameters.Clear()
                    Message("Success.")
                    cboGender.SendToBack()
                    txtAddress.ReadOnly = True
                    txtPassNo.ReadOnly = True
                    txtCardNo.ReadOnly = True
                    txtGender.Text = cboGender.Text
                    cboCusName.Focus()
                End If
                btnNew.Text = "     New"
                PIconButton(4)
            End If
        End If
    End Sub

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        Clearcus()
        txtAddress.ReadOnly = True
        txtPassNo.ReadOnly = True
        cboGender.SendToBack()
        txtCardNo.ReadOnly = True
        cboCusName.Focus()
        btnNew.Text = "     New"
        PIconButton(4)
    End Sub

    Private Sub btnSCustomer_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSCustomer.Click
        If cboCusName.Text = "" Then
            Message("Complete Customer Name to Search.")
            cboCusName.Focus()
        Else
            Com.CommandText = "Select CusID,Gender,Address,PassportNo,CardNo from tblCustomer where " & _
            "CusName='" & cboCusName.Text & "'"
            Dr = Com.ExecuteReader
            If Dr.Read = True Then
                txtCusID.Text = Dr(0)
                txtGender.Text = Dr(1)
                txtAddress.Text = Dr(2)
                txtPassNo.Text = Dr(3)
                txtCardNo.Text = Dr(4)

                'Lock Text Box Read Only
                txtAddress.ReadOnly = True
                txtPassNo.ReadOnly = True
                cboGender.SendToBack()
                txtCardNo.ReadOnly = True
                cboCusName.Focus()
                btnNew.Text = "     New"
                PIconButton(4)
            Else
                Message("Record was Not Found. Please Insert New Customer.")
                cboCusName.Focus()
            End If
            Dr.Close()
        End If
    End Sub

    Private Sub btnBooking_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnBooking.Click
        If cboCusName.Text = "" Then
            Message("Choose one Customer to Booking.")
            cboCusName.Focus()
        ElseIf txtStaying.Text = "" Then
            Message("Complete Number of Staying.")
            txtStaying.Focus()
        ElseIf cboRNum.Text = "" Then
            Message("Choose One Room Number.")
            cboRNum.Focus()
        ElseIf txtPrepaid.Text = "" Then
            Message("Complete Prepaid.")
            txtPrepaid.Focus()
        Else
            Dim CCus, CusRoom As Int32
            CCus = Getid("tblBooking", "ID", "CusID='" & txtCusID.Text & "'") - 1
            If CCus = 0 Then
                CusRoom = Getid("tblBooking", "ID", "RoomNo=" & cboRNum.Text & "") - 1
                If CRoom = 0 Then
                    CID = Getid("tblCheckIn", "CheckInNo", "CusID='" & txtCusID.Text & "'") - 1
                    If CID = 0 Then
                        CRoom = Getid("tblCheckIn", "CheckInNo", "RoomNo=" & cboRNum.Text & "") - 1
                        If CRoom = 0 Then
                            Dim CheckID As Integer
                            CheckID = Getid("tblBooking", "ID")
                            Com.CommandText = "Insert into tblBooking Values(?,?,?,?,?,?,?)"
                            With Com.Parameters
                                .Add("@ChID", OleDbType.Integer).Value = CheckID
                                .Add("@DIn", OleDbType.Date).Value = txtCheckIn.Text
                                .Add("@Staying", OleDbType.Integer).Value = txtStaying.Text
                                .Add("@DOut", OleDbType.Date).Value = DTCheckIn.Text
                                .Add("@CID", OleDbType.VarChar).Value = txtCusID.Text
                                .Add("@RNo", OleDbType.Integer).Value = cboRNum.Text
                                .Add("@Prepaid", OleDbType.Currency).Value = txtPrepaid.Text
                            End With
                            Com.ExecuteNonQuery()
                            Com.Parameters.Clear()
                            Message("Success.")
                            Clearcus()
                            txtStaying.Clear()
                            txtCheckOut.Clear()
                            'txtAmount.Clear()
                            txtTotal.Clear()
                            txtPrepaid.Clear()
                            txtRemain.Clear()
                            cboCusName.Focus()
                        Else
                            Message("Room " & cboRNum.Text & " was not free.")
                        End If
                    Else
                        Message("This Customer was staying.")
                        cboCusName.Focus()
                        cboCusName.SelectAll()
                    End If
                Else
                    Message("Room " & cboRNum.Text & " was Booked already.")
                    cboRNum.Focus()
                End If
            Else
                Message("This Customer's Name was Booking already.")
                cboCusName.Focus()
                cboCusName.SelectAll()
            End If
        End If
    End Sub

    Private Sub cboCusName_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cboCusName.TextChanged
        If cboCusName.Text = "" Then
            Clearcus()
        End If
    End Sub
End Class

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美色网一区二区| 国产伦精一区二区三区| 日本中文在线一区| 久久99深爱久久99精品| 成人一级视频在线观看| 日本道免费精品一区二区三区| 欧美日本在线一区| 国产亚洲一本大道中文在线| 综合分类小说区另类春色亚洲小说欧美| 一二三四社区欧美黄| 男人的j进女人的j一区| 丁香亚洲综合激情啪啪综合| 欧美影视一区在线| 精品少妇一区二区三区| 综合婷婷亚洲小说| 日本特黄久久久高潮| 福利视频网站一区二区三区| 欧美在线观看你懂的| 精品成人在线观看| 亚洲精品国产精华液| 久久www免费人成看片高清| 一本久久综合亚洲鲁鲁五月天| 欧美一区二区私人影院日本| 国产精品久久久久久久岛一牛影视| 亚洲成av人片在www色猫咪| 国产精品99久久久久久久女警 | 欧美videos中文字幕| 国产欧美精品区一区二区三区| 亚洲高清一区二区三区| 国产成人综合精品三级| 在线电影国产精品| 亚洲欧洲三级电影| 韩国av一区二区三区| 欧美色图激情小说| 中文字幕日韩av资源站| 另类小说综合欧美亚洲| 欧美网站大全在线观看| 中文字幕日本乱码精品影院| 免费在线观看一区| 欧美艳星brazzers| 亚洲欧洲性图库| 国产精品99久| 日韩精品一区在线| 三级一区在线视频先锋| 色综合视频一区二区三区高清| 久久天堂av综合合色蜜桃网 | 欧美成人三级在线| 夜夜嗨av一区二区三区网页| 成人午夜视频免费看| 日韩色在线观看| 偷窥国产亚洲免费视频| 色偷偷成人一区二区三区91| 欧美国产日本韩| 国产综合色视频| 精品国产一二三| 久久精品国产成人一区二区三区 | 五月婷婷欧美视频| 色狠狠综合天天综合综合| 国产精品免费aⅴ片在线观看| 久久www免费人成看片高清| 制服丝袜亚洲播放| 图片区日韩欧美亚洲| 欧洲色大大久久| 亚洲一区二区三区四区五区中文| 一本大道久久a久久综合婷婷| 国产精品久久三| 本田岬高潮一区二区三区| 中文字幕乱码亚洲精品一区| 粉嫩嫩av羞羞动漫久久久| 久久女同性恋中文字幕| 国产乱码字幕精品高清av| 亚洲精品一区二区三区蜜桃下载| 久久精品99国产精品日本| 日韩精品一区二| 国产一区二区精品久久91| 久久久久久夜精品精品免费| 国产sm精品调教视频网站| 国产午夜精品一区二区| 国产精品1区2区3区| 国产女人aaa级久久久级| 成人aa视频在线观看| 中文字幕一区av| 色视频成人在线观看免| 一二三区精品视频| 777欧美精品| 国精产品一区一区三区mba视频| 精品国内片67194| 国产精品1区二区.| 亚洲欧美另类综合偷拍| 91黄色小视频| 日韩中文字幕av电影| 欧美成人精品二区三区99精品| 精品一区二区久久| 国产精品久久久久久久久免费相片| 91麻豆免费观看| 亚洲午夜在线电影| 日韩欧美专区在线| 国产精品99久久久久久宅男| 亚洲天堂网中文字| 欧美人动与zoxxxx乱| 黄页网站大全一区二区| 国产精品毛片久久久久久久| 色综合天天综合在线视频| 午夜精品福利一区二区蜜股av| 日韩欧美三级在线| 丁香另类激情小说| 亚洲va国产va欧美va观看| 精品国产人成亚洲区| 99久久国产综合精品色伊| 婷婷一区二区三区| 欧美精品一区二| 色8久久精品久久久久久蜜| 首页国产欧美久久| 国产欧美日韩不卡免费| 欧美伊人久久久久久午夜久久久久| 日韩av一区二| 国产精品入口麻豆原神| 欧美日韩免费一区二区三区视频| 久久99久久久久久久久久久| 国产精品久久久久久久久晋中 | 亚洲mv在线观看| 精品国产一区a| 91高清在线观看| 精品亚洲成a人| 一区二区欧美在线观看| 欧美变态凌虐bdsm| 在线免费观看不卡av| 国产在线精品一区二区| 亚洲国产一区二区三区| 国产亚洲一本大道中文在线| 在线视频欧美精品| 国产精品一区久久久久| 亚洲午夜私人影院| 日本一区二区动态图| 欧美美女直播网站| 成人小视频免费在线观看| 美女一区二区久久| 一区二区三区成人在线视频| 国产欧美一区二区三区在线看蜜臀 | 欧美性受xxxx黑人xyx性爽| 国产毛片精品一区| 日韩高清不卡在线| 亚洲日本中文字幕区| 久久精品日产第一区二区三区高清版 | 精品免费99久久| 在线观看亚洲专区| 成人晚上爱看视频| 久久se这里有精品| 首页国产丝袜综合| 一区二区三区四区av| 日本一区二区免费在线| 欧美一卡二卡在线观看| 在线视频欧美区| 97久久精品人人做人人爽| 国产精品996| 久久成人免费网| 日日摸夜夜添夜夜添国产精品| 亚洲精品视频在线| 国产精品久久影院| 国产清纯美女被跳蛋高潮一区二区久久w| 制服丝袜av成人在线看| 在线观看日韩国产| 91丨porny丨国产| 不卡的电视剧免费网站有什么| 国产精品自在在线| 激情综合色综合久久| 美女网站色91| 另类综合日韩欧美亚洲| 免费成人在线影院| 日本网站在线观看一区二区三区| 亚洲午夜激情av| 亚洲图片有声小说| 亚洲高清免费视频| 亚洲国产日产av| 亚洲高清视频中文字幕| 亚洲高清一区二区三区| 亚洲国产日韩在线一区模特| 亚洲午夜在线视频| 天天亚洲美女在线视频| 亚洲v日本v欧美v久久精品| 亚洲成人综合在线| 偷窥少妇高潮呻吟av久久免费| 午夜久久久久久久久久一区二区| 亚洲超碰精品一区二区| 视频一区中文字幕国产| 日本欧美在线观看| 蜜桃一区二区三区在线| 经典三级在线一区| 国产精品乡下勾搭老头1| 成人午夜免费av| 97国产一区二区| 91久久一区二区| 欧美精选一区二区| 精品国产制服丝袜高跟| 久久精品一区二区三区av| 国产精品视频观看| 亚洲美女偷拍久久| 午夜国产精品一区| 亚洲国产精品久久人人爱| 日韩国产高清在线|