<%@ LANGUAGE="VBSCRIPT" %> <% set upl = Server.CreateObject("SoftArtisans.FileUp") vSupp_code = upl.Form("Supp_code") vItem = upl.Form("Item") vAdd_desc = upl.Form("Add_desc") vquantity = upl.Form("quantity") vUnit = upl.Form("Unit") vPrice = upl.Form("Price") vvat = upl.Form("vat") vpay_term = upl.Form("pay_term") vduration = upl.Form("duration") IMGREVIEW= "IMG" & vSupp_code If upl.Form("Image").TotalBytes <> 0 Then ImagePath1=IMGREVIEW & "." & Right( upl.Form("Image").UserFilename , 3) vImage="images/SalesItem/"& ImagePath1 ImagePath1= "C:/Inetpub/Thai-industry/ExchangeHub/images/SalesItem/"& ImagePath1 upl.Form("Image").SaveAs ImagePath1 %> Photo1 Size= <%=upl.Form("Image").TotalBytes%> bytes
<% Else vImage="no_image" End If %> <% Set ExchangeNetSQL = Server.CreateObject("ADODB.Connection") ExchangeNetSQL.Open "thaiindustry", "tinhosting", "tinhosting" sql1 = "INSERT INTO ExSaleItem " & _ " (Supp_Org, ItemID, ItemDesc, ItemQuantity, UOM, Price, Vat, Payment_term, Duration, ImageFile)" & _ " VALUES ('"&_ vSupp_code &"','"& vItem &"','"& vAdd_desc &"','"&_ vquantity &"','"& vUnit &"','"& vPrice &"','"&_ vvat &"','"& vpay_term &"','"& vduration &"','"&_ vImage &"')" Set RS = ExchangeNetSQL.Execute(sql1) '--------------------------------------------------- %> Demo Registration Demo Registration
Supplier Organization Code <%=vSupp_code%>
Item <%=vItem%>
Additional Description <%=vAdd_desc%>
Quantity <%=vquantity%>
Price/Unit of Measure <%=vPrice & " "%><%=vUnit%>
Value Added Tax <%=vvat%>
Payment Term <%=vpay_term%>
duration <%=vduration%>
Image File <%=vImage%>