Use a button to reset counter

Hi all, I need to have a button that will reset a counter, I need both the button and the counter in the grid, so there will be like 6 of them running at a time, like you would see in an auction.  So when the person pushes the button, it needs to reset the counter, not only for the person who pushed the button, but for anyone else looking at the grid.  I'm not sure how to do all of this??  I can make a simple button and counter that gets reset by it, but not sure how to put it in the grid and would it have to be server side, so that it can update the counter for anyone else looking at it??  I am using VS 2008 VB, do I have to do it in JavaScript or what, do I have to have the computers on the website refresh once a second, so they can keep up with the counters?? really not sure which direction I need to head on this.

Thanks,
Randy
ratkinso666Asked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

daveamourCommented:
Welcome to the problems of web development!
Tell me more about your application in general.
ratkinso666Author Commented:
Well, I, perhaps foolishly, told my church that I thought I could help them setup an online auction, I have most of it figured out, but when it comes to the button, I can track WHO is placing the bid, WHAT they bid on, etc, etc., but not sure how to add a timer and make it so that I have the auction timer reset when the button is pressed and so that anyone on the auction sees it reset.  I have everything in a Datalist currently.  
Thank you for any help you can give!!
spprivateCommented:
Foremost simple solution would be like in ebay or stock ticker sites.
Refresh the page and read the counter from database.
Other option is to go for Ajax where the user doesnt realized that there is a server processing.AJAX is the hot one  to look for
Exploring ASP.NET Core: Fundamentals

Learn to build web apps and services, IoT apps, and mobile backends by covering the fundamentals of ASP.NET Core and  exploring the core foundations for app libraries.

ratkinso666Author Commented:
I would like to do it in AJAX, but not sure how to start it out??  AJAX doesn't have a timer, so not sure how I would set that in the database so that I could read it into my gridview....  and have like 6 independent ones...
spprivateCommented:

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
ratkinso666Author Commented:
Thank you spprivate, that does tell me how to refresh my grid every second, so that the current time remaining displays.  But is the timer supposed to display the time remaining, I don't see how it does, from what I can see, is all it will do is refresh my update panel, which is useful, but still doesn't show a timer.  I can see that I could create fields in my database for hours, minutes and seconds and refresh those in a label maybe??  To show the countdown...  Is that what I would need to do and then that therefore would display a timer, not sure if that is the best way to do, since that would be a LOT of refreshing and traffic.  If that is how I would do it, then how would I make the time update in the database?  Hope that makes sense...

Thank you VERY much
spprivateCommented:
You want to show a timer or ticking clock kind of thing in the page to all the users.that should be reset once a button is clicked.Correct
ratkinso666Author Commented:
yes, that is correct, in a grid for each item, so I could have 6 different clocks running at the same time, but only one at a time gets reset.
spprivateCommented:
Here is an example of timer control in ajax

http://www.codeproject.com/KB/webforms/ServerSideClock.aspx

Here if you look in the last part

"Setting logick on Tick event Here we dont have to do much. just set current date time value to label void timer_Tick(object sender, EventArgs e)"

Where he sets the time,read the time from the database table.
The reset button in the control form would update that table everytime when reset button in clicked
ratkinso666Author Commented:
I will work on it with the info you gave me, but it will take me some time and experimenting to figure out how that is working.
Thanks
ratkinso666Author Commented:
I've been working with this, but unless I am just not getting it correct, which is VERY possible, it only seems to do time, rather than a timer...  I need something that is set to like say 3:00 minutes and starts counting down, unless someone hits the bid button and then it will add like 30 seconds to whatever time is remaining.  I can set up the hours, minutes and seconds in the database, but then unless someone hits the button it will not change, so I need to be able to change the time in the database even when no one is hitting any buttons..  hope that makes sense...  I know it can be done I have seen it on other sites, just not sure how...

thanks,
randy
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
.NET Programming

From novice to tech pro — start learning today.