Sie sind auf Seite 1von 5

Jeesup Manufacturing

The application is a web base Application . The Home Page of the application . The
different wholesaler will use the this page to retrieve information like the Product list
,Company Portfolio, and the Contacts details.
Partial Class _Default
Inherits System.Web.UI.Page

Protected Sub btnproducts_Click(ByVal sender As Object, ByVal e As


System.EventArgs) Handles btnproducts.Click
Response.Redirect("products.aspx")

End Sub

Protected Sub btncontacts_Click(ByVal sender As Object, ByVal e As


System.EventArgs) Handles btncontacts.Click
Response.Redirect("contacts.aspx")
End Sub

Protected Sub btnPortfolio_Click(ByVal sender As Object, ByVal e As


System.EventArgs) Handles btnPortfolio.Click
Response.Redirect("portfolio.aspx")
End Sub

End Class
The login form that the salesman and the company employee use to place an order, new
purchase , create new products, appoint new employee , see the details like emp list.
Protected Sub Page_Load(ByVal sender As Object, ByVal e As
System.EventArgs) Handles Me.Load
If Not IsPostBack Then
Dim i As Integer
Dim userslist As New ArrayList
Dim dr() As DataRow
Dim da As New SqlDataAdapter("select username from users",
ConfigurationManager.AppSettings("connectionString"))
Dim dt As New DataTable
da.Fill(dt)
dr = dt.Select
For i = 0 To dr.Length - 1
userslist.Add(dr(i)(0).ToString)
Next
ddusers.DataSource = userslist
Page.DataBind()
End If
End Sub
The order form is show above
Public Function totalOrderamount(ByVal orderID As String) As Double
Dim comstring As String
Dim total As Double
comstring = "select sum(total) from orderdetails where
orderid='" & orderID & "'"
Dim con As New
SqlConnection(ConfigurationManager.AppSettings("connectionString"))
Dim com As New SqlCommand(comstring, con)
con.Open()
total = com.ExecuteScalar
Return total
End Function

The form for create new product is show below


The database used here is SQL Server and the table list and the detail is show below

CREATE TABLE [dbo].[orderdetails](


[orderID] [tinyint] NULL,
[productname] [nchar](20) COLLATE SQL_Latin1_General_CP1_CI_AS
NULL,
[price] [real] NULL,
[quantity] [int] NULL,
[total] [real] NULL
) ON [PRIMARY]

CREATE TABLE [dbo].[stock](


[Productname] [nchar](20) COLLATE SQL_Latin1_General_CP1_CI_AS NOT
NULL,
[stock] [real] NULL
) ON [PRIMARY]

Das könnte Ihnen auch gefallen