Forum Moderators: open
I implemented a web form that displays a table (System.Web.UI.WebControls.Table) in which i must change the color of the rows at some time interval depending on the data from the cells. The data is read from an Oracle database. The table is displayed ok but i don't know how to generate a page refresh from the code. So far i set a timer function and i want that each time the timer elapsed to refresh the page.
I know that i could do that by java script, but i'm curios what choices i have from C# . I tried using Response.Redirect but it's not working.
Also, how can i change the application so that each time i reload the page to not do the same operations: connect to database, populate the table. Is it a possibility to populate only once the table from the database and then at each refresh to work only with the data from the table?
Hope i made myself clear enough....
Your best bet is to use a JavaScript function, like your timer function, which counts down a specified time, and then calls the URL again, e.g.
//code to count down here
if (time==0) {
window.location.reload;
}
JP