Jump to content

Connecting between a progress bar and a label to FileInstall()


Recommended Posts

You supposed to understand by the examples, especially from the Label's example...

In the progress I want it to show the FileInstall's progress so when the progress is full, FileInstall is done.

In the label I want it to show the current file that FileInstall is installing...

Thanks :)

Link to comment
Share on other sites

The function does not return until the copy part is complete. So the way you want it to work is just not going to work :)

If you really need every file to have a progress, try splitting your file into chunk and then use FileRead / FileWrite to combine them.

Broken link? PM me and I'll send you the file!

Link to comment
Share on other sites

...

Let's say I want to install an archive called "omfglol" to C:\ so it will be

FileInstall("omfglol","C:\")

Now, in omfglol, there's 2 songs that weight about 3mb.

So I want the label to show:

"Now Installing: song1"

And when the song1 installation is over, I want it to show:

"Now Installing: song2"

Do you understand me?

I think it will be a code with

While $FileInstall
;do what I want...
WEnd

And about the progress,

I don't want every file to have a progress, I want the progress bar to show the FileInstall's progress...

Thanks...

Edited by Info
Link to comment
Share on other sites

I don't want to extract the files

You know what, forget about the crappy label

what about the progress?

There's no progress:Your script'll be paused until FileInstall finishes it's job.The only way to have a progress is using other means of compression,and decompressing in runtime,capturing the output and showing the progressbar.

Resuming, FileInstall = No progress

Link to comment
Share on other sites

I don't want to extract the files

You know what, forget about the crappy label

what about the progress?

If you just want to display the name of the file being installed then this will work

GUICtrlSetData($Label,"Now Installing: " & "abcdefg.txt")
$var = FileInstall("abc.txt","abcdefg.txt")
If $var = 1 Then 
    GUICtrlSetData($Label,"Sucessfully Installed: " & "abcdefg.txt")
Else
    GUICtrlSetData($Label,"Failed to Install: " & "abcdefg.txt")
EndIfoÝ÷ Øò¢ìÛ(²0¶©®+(}ªZ®ØºV«~)^ºÈ§X¥x쵩e×Ú-mçhæ(»¥¯zÚ+y§mçâç!ºyÉÈnF§w
âµè­¢ëéäo'!ºy.²)à)^EæjwEW®+^!ü¨¹ªÞºÈ§k¥¶*exX¥x쵩e¶§¶¬Â¥vÈhÂØ^¦º ­ë,¡ûazÚ-jX§²Ö¥»­bدÛø¥zÆ®¶­sduT7G&Å6WDFFb33cµ&öw&W74&"âb33c·f"ÒfÆTç7FÆÂgV÷C´fÆSçGBgV÷C²ÂgV÷C´fÆSçGBgV÷C²¤uT7G&Å6WDFFb33cµ&öw&W74&"ÂóR¢ ¢b33c·f"ÒfÆTç7FÆÂgV÷C´fÆS"çGBgV÷C²ÂgV÷C´fÆS'çGBgV÷C²¤uT7G&Å6WDFFb33cµ&öw&W74&"Â"óR¢ ¢b33c·f"ÒfÆTç7FÆÂgV÷C´fÆS2çGBgV÷C²ÂgV÷C´fÆS7çGBgV÷C²¤uT7G&Å6WDFFb33cµ&öw&W74&"Â2óR¢ ¢b33c·f"ÒfÆTç7FÆÂgV÷C´fÆSBçGBgV÷C²ÂgV÷C´fÆSGçGBgV÷C²¤uT7G&Å6WDFFb33cµ&öw&W74&"ÂBóR¢ ¢b33c·f"ÒfÆTç7FÆÂgV÷C´fÆSRçGBgV÷C²ÂgV÷C´fÆSWçGBgV÷C²¤uT7G&Å6WDFFb33cµ&öw&W74&"ÂRóR¢

"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the universe trying to build bigger and better idiots. So far, the universe is winning."- Rick Cook

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...