<%@ Language=VBScript %> <% Response.Buffer=true %> Laundry Carts
Account Access

<% Dim LaunConn Dim CookCartID Dim objFSO Set LaunConn=Server.CreateObject("ADODB.Connection") LaunConn.Open "DSN=LaundryCarts;" CookCartID = Session("CookCartID") CustID = Session("CustID") %>


Parts Administration
<%if Session("level") <> 4 and Request.querystring("CustID") <> CustID2 then response.redirect ("http://www.laundry-carts.com") end if%>
Add Part <%=request.form("partnumber")%>
<% partnumber = Replace(request.form("partnumber"), "'", "''") PartDescription = trim(Replace(request.form("PartDescription"), "'", "''")) LongDescription1 = trim(Replace(request.form("LongDescription1"), "'", "''")) LongDescription2 = trim(Replace(request.form("LongDescription2"), "'", "''")) if request.form("price") = "" then price = "none" else price = formatcurrency(Replace(request.form("price"), "'", "''"), 2) end if if request.form("weight") = "" then weight = "0" else weight = formatnumber(Replace(request.form("price"), "'", "''"), 2) end if Category = request.form("Category") if partnumber = "" then errortext = errortext & "You must provide a part number.
" end if if PartDescription = "" then errortext = errortext & "You must provide a short part description.
" end if if price = "none" then errortext = errortext & "You must provide a price.
" end if sql = "INSERT INTO " & Category &"(partnumber, partdescription, longdescription1, longdescription2, price, weight) " sql = sql & "VALUES('" & partnumber & "', '" & partdescription & "', '" & longdescription1 & "', '" & longdescription2 & "', '" sql = sql & price & "', " & weight & ");" LaunConn.execute(sql) LaunConn.Close Set LaunConn = Nothing %> <%if errortext = "" then%> <%else%> <%end if%>
Part added to database!
Click here to return to the parts administration page.
Part was NOT added to the database due the following errors:

<%=errortext%>

Return to Menu
 
Call Us: 1-866-891-5513, Email Us: parts@sterlingequipmentco.com
All contents © copyright 2004 Laundry Cart Co., All rights reserved.