Solved

Reverse Countdown

Posted on 2007-11-27
4
193 Views
Last Modified: 2010-04-21
Hi Experts,

I am trying to do the following but no luck yet! Hope you can help!

Using a progressbar I am setting the position to a countdown from Edit1.text.

So I've created an Integer Variable and Assigned it to the Initial Number, which I've also set as the
progressbar .max.

Do basically everytime something happens it's counting down.

Now, what I need to do is have another variable that will count up everytime the edit counts down
so I can assign that variable to the progressbar position.

I hope this makes sense to you ;o)

How could I do this please?

Thanks

ST3VO
0
Comment
Question by:ST3VO
  • 2
  • 2
4 Comments
 
LVL 19

Expert Comment

by:MerijnB
ID: 20361475
I don't understand your question.

What is in Edit1.Text?
What is triggering the 'countdown'?
0
 

Author Comment

by:ST3VO
ID: 20361516
The countdown is the ListView.items.count

Then it goes through a loop and everytime to in loops it counts the number of lines left in the listview.

I've put the countdown to show in a TEdit.

Suppose the initial ListView count is 150

Then I've assigned to progressbbar.max position to 150

I don't want to progressbar to go from 150 to 0

I need it to go from 0 to 150

So I want to somehow, assign another variable that will Increment everytime the value of the
countdown descreases.

Hope this helps :o)

Thanks

ST3VO
0
 
LVL 19

Accepted Solution

by:
MerijnB earned 500 total points
ID: 20361537
how about:
progressbar.position := progressbar.max - listview.items.count;

Open in new window

0
 

Author Closing Comment

by:ST3VO
ID: 31411298
Perfect! Thanks a million :o)
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question