Sending new database records to the website

Repentless

New Member
We have several terminals throughout the plant that employees will be using to submit part requests through our supply/warehouse department.This Supply Warehouse will have a terminal displaying an "orders" website, showing a list of part numbers and the employees who are waiting for them.Everything works now, but I only know how to get the data to refresh by coding in a \[code\]<META REFRESH>\[/code\] tag, which doesn't really work well and causes a lot of other information on the form to get lost in the process.How would I go about telling the webpage to "listen" for changes or simply update the GridView once a minute or so?I've seen websites do it. This site pops up a note as soon as someone responds, finance sites pop up the latest stock quotes every few seconds, etc. I don't know what the technology is called or how I would use it.Do I write some code in the codebehind?\[code\]protected void Page_Load(object sender, EventArgs e) { // ???}\[/code\]Here is the basics of what I have.\[code\]<asp:SqlDataSource ID="productionDataSource2" runat="server" ConnectionString="<%$ ConnectionStrings:CPWEB_PRODUCTION %>" SelectCommand="SELECT [RequestID], [Employee], [DateStamp], [Line], [PartNo], [Workorder], [Qty], [MTF], [Status] FROM [vwRequestsEx] WHERE ([Status] = @Status)"><SelectParameters> <asp:ControlParameter ControlID="ddlSelector" Name="Status" PropertyName="SelectedValue" Type="String" /> </SelectParameters></asp:SqlDataSource><asp:GridView ID="GridView1" runat="server" AllowPaging="True" AllowSorting="True" AutoGenerateColumns="False" AutoGenerateSelectButton="True" CellPadding="1" DataSourceID="productionDataSource2" EmptyDataText="No Records to Display" Font-Size="Small" ForeColor="#333333" OnSelectedIndexChanged="GridViewRow_Selected" ShowHeaderWhenEmpty="True" HorizontalAlign="Left" RowHeaderColumn="RequestID" Width="95%"> <Columns> <asp:BoundField DataField="RequestID" HeaderText="RequestID" SortExpression="RequestID" /> <asp:BoundField DataField="Employee" HeaderText="Employee" SortExpression="Employee" /> <asp:BoundField DataField="DateStamp" HeaderText="DateStamp" SortExpression="DateStamp" /> <asp:BoundField DataField="Line" HeaderText="Line" SortExpression="Line" /> <asp:BoundField DataField="PartNo" HeaderText="PartNo" SortExpression="PartNo" /> <asp:BoundField DataField="Workorder" HeaderText="Workorder" SortExpression="Workorder" /> <asp:BoundField DataField="Qty" HeaderText="Qty" SortExpression="Qty" /> <asp:BoundField DataField="MTF" HeaderText="MTF" SortExpression="MTF" /> <asp:BoundField DataField="Status" HeaderText="Status" SortExpression="Status" /> </Columns></asp:GridView>\[/code\]I'm getting a lot of downvotes lately. Downvoters: That's OK, but kindly let me know why so I'll understand what is wrong.
 
Back
Top