Table problems as well....

admin

Administrator
Staff member
so...I am completely new to this and I am only doing it for a class project...kinda fun...but html sucks...anyway...<br />
<br />
I got the drop down menu to select the right company...so it then enters the "store ID" I selected into the right place....but then on my table it shows all my stores not just the one I selected...and I need it to show only the store I selected...what do I do?????<br />
<br />
Here is my code...<br />
<br />
%><br />
</select><br />
<br><br />
<input type="Submit" value="Get store Info"> <br />
</form> <br />
</body> <br />
</html> <br />
<% ELSE %> <br />
<html> <br />
<title>Your store inventory list</title> <br />
<body> <br />
<h1>Inventory List</h1> <br />
Here is the inventory list for your store:<BR> <br />
<form method="post" action="UpdateInventory.asp"> <br />
<input type=hidden name=storeid value=<%=Request.form("StoreID")%> ><br />
The inventory list you chose is for store number <br />
<%<br />
SQL = "SELECT storeid FROM StoreManager where StoreID=" & Request.form("storeid")<br />
set theusers=conn.execute(SQL)<br />
response.write theusers(0)<br />
SQL = "SELECT dbo.StoreManager.storeid, dbo.Inventory.itemid, dbo.Items.productname, dbo.Items.price, dbo.Items.cost, dbo.Items.description, dbo.Inventory.quantityonhand, dbo.Inventory.reorderpoint FROM dbo.Inventory INNER JOIN dbo.StoreManager ON dbo.Inventory.storeid = dbo.StoreManager.storeid INNER JOIN dbo.Items ON dbo.Inventory.itemid = dbo.Items.itemid" & Request.form("storemanager where storeid")<br />
<br />
set theusers=conn.execute(SQL)<br />
%><br />
<table border=1><br />
<tr><br />
<th>Store ID</th><br />
<th>Item ID</th><br />
<th>Item Name</th><br />
<th>Selling Price</th><br />
<th>order Cost</th><br />
<th>Item Description</th><br />
<th>Quantity on hand</th><br />
<th>Reorder Point</th><br />
</tr><br />
<%<br />
do while not theusers.eof<br />
response.write("<tr><td>"& theusers(0) & "</td><td>" & theusers(1) & "</td><td>" & theusers(2) & "</td><td>$"& theusers(3) & "</td><td>$"& theusers(4) & "</td><td>"& theusers(5) & "</td><td>"& theusers(6) & "</td><td>"& theusers(7) & "</td><td>" & "</tr>")<br />
theusers.movenext<br />
loop<br />
%><br />
<br />
<br />
Since I am new to this I think I have tried everything and it still is not working....Cindo<!--content-->This looks like a problem for the ASP forum. They'd be better prepared to help you out.<!--content-->To begin with, change <th> and </th> into <td> and </td>.<br />
<br />
SORRY, this reply is nonsence. I take back my words. Good luck.<br />
<br />
Cheers, Jochem :cool:<!--content-->
 
Back
Top