Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How create a install program with a progressbar
#11
Remexx,

I would ignore all this garbage about PowerBasic.

Unless the progress-bar is an absolute necessity for your program, I would forget about it. Otherwise, you will spend 80% of your programming and debuging time just on this one feature of your program.

Another alternative is to display a message like this:
... Installation is xx% complete ...

and keep updating the xx percentage as your program progresses. Many Microsoft utilities do this.
*****
Reply
#12
Quote:Another alternative is to display a message like this:
... Installation is xx% complete ...

and keep updating the xx percentage as your program progresses.*****

Is that really so different from a progress bar?
If you have calculated that percentage, displaying a progress bar is an after thought. Determining that percentage is the bulk of the work.
Reply
#13
You need to set up graphics routines...
Peace cannot be obtained without war. Why? If there is already peace, it is unnecessary for war. If there is no peace, there is already war."

Visit www.neobasic.net to see rubbish in all its finest.
Reply
#14
Is there not a way to find the size of a file?
quote="Deleter"]judging gameplay, you can adaquately compare quake 4 with pong[/quote]
Reply
#15
You can get the size of an open file with LOF. The best way to do this is probably to open the source and destination files yourself and copy blocks from one to the other, displaying a progress bar with (bytes copied / total bytes).
Reply
#16
Quote:You can get the size of an open file with LOF. The best way to do this is probably to open the source and destination files yourself and copy blocks from one to the other, displaying a progress bar with (bytes copied / total bytes).

Using a LOF to get the exact size of each file is an elegant solution which then enables you to make the percentage of completeness more precise. Add up all the file sizes to a total. As you finish the copy for a particular file, add that file's size divided by the total to the percentage complete and display it.

This file-by-file cumulative progress is good enough in my opinion. You just want to give the user a feeling of the progress.

I would stay away from copying the files internally via the program. This approach has many pitfalls, so unless you're an expert on copying files, I would stick to the original suggestion of using a SHELL to a COPY command for each file.
*****
Reply
#17
Install.zip
Instald6.zip
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)