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

📄 userhome.aspx

📁 online book store working project
💻 ASPX
📖 第 1 页 / 共 3 页
字号:
        
        sqlcon.Close()
    End Sub

    Protected Sub btbook7_Click(ByVal sender As Object, ByVal e As System.EventArgs)
        sqlcon = New SqlConnection("Data Source=.; database =BookStore;Integrated Security=True")
        sql1.SelectCommand = New SqlCommand
        sql1.SelectCommand.Connection = sqlcon
        sql1.SelectCommand.CommandText = "select * from tbaddcart"
       
        Dim status As String
        Dim type As String
        Dim prod As String
        Dim name As String
        prod = "The Whole Truth"
        name = "David Baldacci"
        Dim price As String
        price = "237"
        type = "Book"
        status = "Not Purchased"
        sql1.Fill(ds, "tbaddcart")
        demp1 = ds.Tables("tbaddcart")
        dr1 = ds.Tables("tbaddcart").NewRow
        dr1.Item(0) = Session("username")
        dr1.Item(1) = prod
        dr1.Item(2) = price
        dr1.Item(3) = name
        dr1.Item(4) = type
        ds.Tables("tbaddcart").Rows.Add(dr1)
        sql1.InsertCommand = New SqlCommand
        sql1.InsertCommand.Connection = sqlcon
        sql1.InsertCommand.CommandText = "insert into tbaddcart(CustomerId, ProductName, ProductPrice,Author,Type,Status) values('" & Session("username") & "','" & prod & "','" & price & "','" & name & "','" & type & "','" & status & "')"
        sql1.Update(dr1.Table)
              
        MsgBox("* Product has been added to cart", MsgBoxStyle.Information, "Product Added")
        
        sqlcon.Close()
    End Sub

    Protected Sub btbook8_Click(ByVal sender As Object, ByVal e As System.EventArgs)
        sqlcon = New SqlConnection("Data Source=.; database =BookStore;Integrated Security=True")
        sql1.SelectCommand = New SqlCommand
        sql1.SelectCommand.Connection = sqlcon
        sql1.SelectCommand.CommandText = "select * from tbaddcart"
       
        Dim status As String
        Dim type As String
        Dim prod As String
        Dim name As String
        prod = "Duma Key"
        name = "Stephen King"
        Dim price As String
        price = "237"
        type = "Book"
        status = "Not Purchased"
        sql1.Fill(ds, "tbaddcart")
        demp1 = ds.Tables("tbaddcart")
        dr1 = ds.Tables("tbaddcart").NewRow
        dr1.Item(0) = Session("username")
        dr1.Item(1) = prod
        dr1.Item(2) = price
        dr1.Item(3) = name
        dr1.Item(4) = type
        ds.Tables("tbaddcart").Rows.Add(dr1)
        sql1.InsertCommand = New SqlCommand
        sql1.InsertCommand.Connection = sqlcon
        sql1.InsertCommand.CommandText = "insert into tbaddcart(CustomerId, ProductName, ProductPrice,Author,Type,Status) values('" & Session("username") & "','" & prod & "','" & price & "','" & name & "','" & type & "','" & status & "')"
        sql1.Update(dr1.Table)
              
        MsgBox("* Product has been added to cart", MsgBoxStyle.Information, "Product Added")
        
        sqlcon.Close()
    End Sub

    Protected Sub btbook9_Click(ByVal sender As Object, ByVal e As System.EventArgs)
        sqlcon = New SqlConnection("Data Source=.; database =BookStore;Integrated Security=True")
        sql1.SelectCommand = New SqlCommand
        sql1.SelectCommand.Connection = sqlcon
        sql1.SelectCommand.CommandText = "select * from tbaddcart"
       
        Dim status As String
        Dim type As String
        Dim prod As String
        Dim name As String
        prod = "Knots And No(Crosses)"
        name = "Hitesha Deshpande"
        Dim price As String
        price = "175"
        type = "Book"
        status = "Not Purchased"
        sql1.Fill(ds, "tbaddcart")
        demp1 = ds.Tables("tbaddcart")
        dr1 = ds.Tables("tbaddcart").NewRow
        dr1.Item(0) = Session("username")
        dr1.Item(1) = prod
        dr1.Item(2) = price
        dr1.Item(3) = name
        dr1.Item(4) = type
        ds.Tables("tbaddcart").Rows.Add(dr1)
        sql1.InsertCommand = New SqlCommand
        sql1.InsertCommand.Connection = sqlcon
        sql1.InsertCommand.CommandText = "insert into tbaddcart(CustomerId, ProductName, ProductPrice,Author,Type,Status) values('" & Session("username") & "','" & prod & "','" & price & "','" & name & "','" & type & "','" & status & "')"
        sql1.Update(dr1.Table)
              
        MsgBox("* Product has been added to cart", MsgBoxStyle.Information, "Product Added")
        
        sqlcon.Close()
    End Sub

    Protected Sub btbook10_Click(ByVal sender As Object, ByVal e As System.EventArgs)
        sqlcon = New SqlConnection("Data Source=.; database =BookStore;Integrated Security=True")
        sql1.SelectCommand = New SqlCommand
        sql1.SelectCommand.Connection = sqlcon
        sql1.SelectCommand.CommandText = "select * from tbaddcart"
       
        Dim status As String
        Dim type As String
        Dim prod As String
        Dim name As String
        prod = "Narendra Modi-The(Architect)of A Modern State"
       
        name = "M.V. Kamath And Kalindi Randeri"

        Dim price As String
        price = "395"
        type = "Book"
        status = "Not Purchased"
        sql1.Fill(ds, "tbaddcart")
        demp1 = ds.Tables("tbaddcart")
        dr1 = ds.Tables("tbaddcart").NewRow
        dr1.Item(0) = Session("username")
        dr1.Item(1) = prod
        dr1.Item(2) = price
        dr1.Item(3) = name
        dr1.Item(4) = type
        ds.Tables("tbaddcart").Rows.Add(dr1)
        sql1.InsertCommand = New SqlCommand
        sql1.InsertCommand.Connection = sqlcon
        sql1.InsertCommand.CommandText = "insert into tbaddcart(CustomerId, ProductName, ProductPrice,Author,Type,Status) values('" & Session("username") & "','" & prod & "','" & price & "','" & name & "','" & type & "','" & status & "')"
        sql1.Update(dr1.Table)
              
        MsgBox("* Product has been added to cart", MsgBoxStyle.Information, "Product Added")
        
        sqlcon.Close()
    End Sub

    Protected Sub btcd1_Click(ByVal sender As Object, ByVal e As System.EventArgs)
        sqlcon = New SqlConnection("Data Source=.; database =BookStore;Integrated Security=True")
        sql1.SelectCommand = New SqlCommand
        sql1.SelectCommand.Connection = sqlcon
        sql1.SelectCommand.CommandText = "select * from tbaddcart"
       
        Dim status As String
        Dim type As String
        Dim prod As String
        Dim name As String
        prod = "Medal of Honor Pacific Assault"
       
        name = "Unknown"

        Dim price As String
        price = "1299"
        type = "Game"
        status = "Not Purchased"
        sql1.Fill(ds, "tbaddcart")
        demp1 = ds.Tables("tbaddcart")
        dr1 = ds.Tables("tbaddcart").NewRow
        dr1.Item(0) = Session("username")
        dr1.Item(1) = prod
        dr1.Item(2) = price
        dr1.Item(3) = name
        dr1.Item(4) = type
        ds.Tables("tbaddcart").Rows.Add(dr1)
        sql1.InsertCommand = New SqlCommand
        sql1.InsertCommand.Connection = sqlcon
        sql1.InsertCommand.CommandText = "insert into tbaddcart(CustomerId, ProductName, ProductPrice,Author,Type,Status) values('" & Session("username") & "','" & prod & "','" & price & "','" & name & "','" & type & "','" & status & "')"
        sql1.Update(dr1.Table)
              
        MsgBox("* Product has been added to cart", MsgBoxStyle.Information, "Product Added")
        
        sqlcon.Close()
    End Sub

    Protected Sub btcd2_Click(ByVal sender As Object, ByVal e As System.EventArgs)
        sqlcon = New SqlConnection("Data Source=.; database =BookStore;Integrated Security=True")
        sql1.SelectCommand = New SqlCommand
        sql1.SelectCommand.Connection = sqlcon
        sql1.SelectCommand.CommandText = "select * from tbaddcart"
       
        Dim status As String
        Dim type As String
        Dim prod As String
        Dim name As String
        prod = "Need for speed Underground 2"
       
        name = "Unknown"

        Dim price As String
        price = "1299"
        type = "Game"
        status = "Not Purchased"
        sql1.Fill(ds, "tbaddcart")
        demp1 = ds.Tables("tbaddcart")
        dr1 = ds.Tables("tbaddcart").NewRow
        dr1.Item(0) = Session("username")
        dr1.Item(1) = prod
        dr1.Item(2) = price
        dr1.Item(3) = name
        dr1.Item(4) = type
        ds.Tables("tbaddcart").Rows.Add(dr1)
        sql1.InsertCommand = New SqlCommand
        sql1.InsertCommand.Connection = sqlcon
        sql1.InsertCommand.CommandText = "insert into tbaddcart(CustomerId, ProductName, ProductPrice,Author,Type,Status) values('" & Session("username") & "','" & prod & "','" & price & "','" & name & "','" & type & "','" & status & "')"
        sql1.Update(dr1.Table)
              
        MsgBox("* Product has been added to cart", MsgBoxStyle.Information, "Product Added")
        
        sqlcon.Close()
    End Sub

    Protected Sub btcd3_Click(ByVal sender As Object, ByVal e As System.EventArgs)
        sqlcon = New SqlConnection("Data Source=.; database =BookStore;Integrated Security=True")
        sql1.SelectCommand = New SqlCommand
        sql1.SelectCommand.Connection = sqlcon

⌨️ 快捷键说明

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