To register for an Internet.com membership to receive newsletters and white papers, use the Register button ABOVE.
To participate in the message forums BELOW, click here
VBForums  

VB Wire News
Part 10 of the Visual Basic .NET 2010 Express Tutorial Complete!
How to Use the Visual Studio Code Analysis Tool FxCop
Article :: Interview with Andrei Alexandrescu (Part 3 of 3)
Introducing Visual Studio LightSwitch
Visual Studio LightSwitch Beta 1 is Available



Go Back   VBForums > VBForums CodeBank > CodeBank - Visual Basic 6 and earlier

Reply Post New Thread
 
Thread Tools Display Modes
Old Oct 26th, 2004, 09:31 AM   #1
Wokawidget
Super Moderator
 
Wokawidget's Avatar
 
Join Date: Nov 01
Location: Headingly Occupation: Classified
Posts: 9,589
Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)
VB Downloader. Download files from the web, with prog bar.

There are 2 downloader projects attached here. 1 asynchronous project and 1 synchronous project.

The synchronous downloader, vbDownloader.zip, uses the URLDownload API and uses call backs to allow the user to cancel the download and/or show a prog bar.

For this project to work you need to do the following:

Attached is code, plus a demo app, that allows you to download files from the web.
This can be used for auto updates for a client exe etc, or just as a download manager.

One thing you need to do is download the file:

http://www.mvps.org/emorcillo/download/vb6/tl_ole.zip

and extract the 2 tlb files and install them using the instructions provided.

These tlb files are used for the call back to allow the download to be shown in a progress bar, and to allow the user to cancel the download.



The 2nd project "Downloader and Winsock.zip" is an asynchronous downloader that uses a DLL version of the winsock control.
This has a few benefits over the URLDownload method. 1stly it's asynchronous and there you can have multiple downloads at any one time in your app, plus it allows you to use your app while downloading. It also allows you to get the file size of the file before you download it. This I find is very usefull.
However, the URLDownload example allows you to cache the file in the internet cache folder....this can be handy. The winsock does not cache any of the file, and if the download is aborted cancelled you will have to download the whole file from scratch.

Pick ya method

Woka
Attached Files
File Type: zip vbdownloader.zip (5.0 KB, 9730 views)
File Type: zip Downloader And Winsock.zip (34.8 KB, 7809 views)
__________________
My .NET Tutorials:
Silverlight Enabled WebPart in WSS

My VB.NET Code Examples:
Create IIS Virtual DirectoryValidate Login Against Active DirectoryAutomatically retrieve Identity field value from inserted DataRow using SQL Server and ADO.NET

My ASP.NET Code Examples:
Login To Website (Forms Authentication)Login To Website (Custom Authentication)

My VB6 Code Projects:
Multithreading In VB6Custom TooltipsMulti Language SupportItem Selector ControlAnnimated Systray IconSimple Effective Graph ControlDownload From WebLiveUpdate, download application updates from the web automaticallySystray Notification MessagesSkin A FormAPI TimerBadger Messenger, an MSN clone that uses the MSN NetworkWokawidgets VB6 Component Suite

Last edited by Wokawidget; Apr 15th, 2005 at 03:33 AM.
Wokawidget is offline   Reply With Quote
Old Nov 9th, 2004, 11:29 AM   #2
kleinma
Moderator.NET
 
kleinma's Avatar
 
Join Date: Nov 01
Location: NJ - USA (Near NYC)
Posts: 22,482
kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)
hey where's my name in the credits
__________________
Using VB.NET 2010/.NET 2.0 through 4.0 * Please mark you thread resolved using the Thread Tools above
PLEASE INDICATE WHAT VERSION OF VB YOU USE!!!!!!!!!!!
* If you found a post useful then please Rate it! * DO NOT PM ME WITH LINKS TO YOUR THREADS FOR ANSWERS PLEASE!

Code Bank:Manipulate HTML Page content in the Web Browser Control from VB - Drag Drop from Windows into Win Form - Launch new default browser instance to open URL - Display Internet Image in Picturebox - Download Files From Web With Progress Bar - IP Textbox User Control - Installing .NET Framework with INNO Setup
ZerosAndTheOne.com
-=Matt=-
kleinma is offline   Reply With Quote
Old Dec 5th, 2004, 01:02 PM   #3
TheVader
Fanatic Member
 
TheVader's Avatar
 
Join Date: Oct 02
Location: Rotterdam, the Netherlands
Posts: 871
TheVader will become famous soon enough (65+)
Re: VB Downloader. Download files from the web, with prog bar.

Nice code, worked fine for me in the IDE. But when I compiled both files (vbWebDownload.dll and DemoDownloadApp.exe) the app didn't work anymore. When trying to download a file the app hangs and after a while says 'Download aborted. Resource not found.' Without error handler it gave me a 'Object variable or With block variable not set' error and an Automation error. Does this happen with anyone else when the app is compiled?
__________________
Author for Visual Basic Web Magazine
My articles on the Web Browser Control:
Using the Web Browser Control & Using the DHTML Document Object Model

The examples referenced in the articles can be found here:
TheVader is offline   Reply With Quote
Old Jan 18th, 2005, 05:42 PM   #4
Wokawidget
Super Moderator
 
Wokawidget's Avatar
 
Join Date: Nov 01
Location: Headingly Occupation: Classified
Posts: 9,589
Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)
Re: VB Downloader. Download files from the web, with prog bar.

When you copyied both the tlb files to system32, did you register them using the instructions on the web site, or did you just browse to the files in VB and register them that way?

Just asking as that's the only thing I can think of off the top of my head.

Will have a go myself tomorrow to see if I can crash it.

Woka
__________________
My .NET Tutorials:
Silverlight Enabled WebPart in WSS

My VB.NET Code Examples:
Create IIS Virtual DirectoryValidate Login Against Active DirectoryAutomatically retrieve Identity field value from inserted DataRow using SQL Server and ADO.NET

My ASP.NET Code Examples:
Login To Website (Forms Authentication)Login To Website (Custom Authentication)

My VB6 Code Projects:
Multithreading In VB6Custom TooltipsMulti Language SupportItem Selector ControlAnnimated Systray IconSimple Effective Graph ControlDownload From WebLiveUpdate, download application updates from the web automaticallySystray Notification MessagesSkin A FormAPI TimerBadger Messenger, an MSN clone that uses the MSN NetworkWokawidgets VB6 Component Suite
Wokawidget is offline   Reply With Quote
Old Jan 26th, 2005, 01:13 PM   #5
NoteMe
Retired G&G Mod
 
NoteMe's Avatar
 
Join Date: Oct 02
Location: @ Opera Software
Posts: 10,190
NoteMe is a glorious beacon of light (400+)NoteMe is a glorious beacon of light (400+)NoteMe is a glorious beacon of light (400+)NoteMe is a glorious beacon of light (400+)NoteMe is a glorious beacon of light (400+)
Re: VB Downloader. Download files from the web, with prog bar.

Sorry...but no more downloading for you...my domain went out today...I have a backup of your files though. And I can upload it as fast as I get the new server up and running if you want that....



ØØ
__________________
NoteMe is offline   Reply With Quote
Old Jan 26th, 2005, 01:32 PM   #6
Wokawidget
Super Moderator
 
Wokawidget's Avatar
 
Join Date: Nov 01
Location: Headingly Occupation: Classified
Posts: 9,589
Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)
Re: VB Downloader. Download files from the web, with prog bar.

Arrrrrgh! Who do you think you are taking down your own server!

Hehehe

Yea, that would be good if you could. They were for my live update code anyways...so wrong thread

Woka
__________________
My .NET Tutorials:
Silverlight Enabled WebPart in WSS

My VB.NET Code Examples:
Create IIS Virtual DirectoryValidate Login Against Active DirectoryAutomatically retrieve Identity field value from inserted DataRow using SQL Server and ADO.NET

My ASP.NET Code Examples:
Login To Website (Forms Authentication)Login To Website (Custom Authentication)

My VB6 Code Projects:
Multithreading In VB6Custom TooltipsMulti Language SupportItem Selector ControlAnnimated Systray IconSimple Effective Graph ControlDownload From WebLiveUpdate, download application updates from the web automaticallySystray Notification MessagesSkin A FormAPI TimerBadger Messenger, an MSN clone that uses the MSN NetworkWokawidgets VB6 Component Suite
Wokawidget is offline   Reply With Quote
Old Jan 27th, 2005, 02:58 PM   #7
NoteMe
Retired G&G Mod
 
NoteMe's Avatar
 
Join Date: Oct 02
Location: @ Opera Software
Posts: 10,190
NoteMe is a glorious beacon of light (400+)NoteMe is a glorious beacon of light (400+)NoteMe is a glorious beacon of light (400+)NoteMe is a glorious beacon of light (400+)NoteMe is a glorious beacon of light (400+)
Re: VB Downloader. Download files from the web, with prog bar.

Oppps....well let me continue in the wrong thread then...

I have my new host, more or less up and running, some countries might not reach it before a day or two. But at least it is up again. You might have to check if it is still working though. I don't know squat about DNS and stuff...but it is somehow chaned, but the name is still the same, just the IP that has changet I guess.


ØØ
__________________
NoteMe is offline   Reply With Quote
Old Mar 26th, 2005, 02:58 AM   #8
dos5731
Banned
 
Join Date: Mar 05
Posts: 26
dos5731 is an unknown quantity at this point (<10)
Re: VB Downloader. Download files from the web, with prog bar.

it works here.
dos5731 is offline   Reply With Quote
Old Sep 13th, 2005, 09:52 PM   #9
willytb
New Member
 
Join Date: Jul 05
Location: Surrey, BC Canada
Posts: 3
willytb is an unknown quantity at this point (<10)
Re: VB Downloader. Download files from the web, with prog bar.

Hope it's not too late to reply to this.....

I can't seem to get the vb downloader code to work I have added the reference to olelib.tlb but when I run the code i get:

Compile error user-defined type not defined?
WithEvents mobjDownload As Download

Also I got a lot of .inc files with the .tlb file but didn't see any instruction in the zip? Only found one file to reference olelib.tlb?

Bill bowman
willytb is offline   Reply With Quote
Old Sep 14th, 2005, 02:45 AM   #10
Wokawidget
Super Moderator
 
Wokawidget's Avatar
 
Join Date: Nov 01
Location: Headingly Occupation: Classified
Posts: 9,589
Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)
Re: VB Downloader. Download files from the web, with prog bar.

That can be a bit messy to setup from what I've heard

Have you tried the 2nd download, the one that uses a custom winsock class.?
This is a much better download project in my opinion.

In your main app do you have reference to vbDownloader?

Woka
__________________
My .NET Tutorials:
Silverlight Enabled WebPart in WSS

My VB.NET Code Examples:
Create IIS Virtual DirectoryValidate Login Against Active DirectoryAutomatically retrieve Identity field value from inserted DataRow using SQL Server and ADO.NET

My ASP.NET Code Examples:
Login To Website (Forms Authentication)Login To Website (Custom Authentication)

My VB6 Code Projects:
Multithreading In VB6Custom TooltipsMulti Language SupportItem Selector ControlAnnimated Systray IconSimple Effective Graph ControlDownload From WebLiveUpdate, download application updates from the web automaticallySystray Notification MessagesSkin A FormAPI TimerBadger Messenger, an MSN clone that uses the MSN NetworkWokawidgets VB6 Component Suite
Wokawidget is offline   Reply With Quote
Old Sep 14th, 2005, 11:36 AM   #11
willytb
New Member
 
Join Date: Jul 05
Location: Surrey, BC Canada
Posts: 3
willytb is an unknown quantity at this point (<10)
Smile Re: VB Downloader. Download files from the web, with prog bar.

Thanks for your quick response. I have gotten it working now and really like how well it works. Not completely sure how to integrate the code into my project though. Can I just copy the frmMain code into my project and reference the vbwebdownload.dll?
willytb is offline   Reply With Quote
Old Sep 14th, 2005, 12:07 PM   #12
Wokawidget
Super Moderator
 
Wokawidget's Avatar
 
Join Date: Nov 01
Location: Headingly Occupation: Classified
Posts: 9,589
Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)
Re: VB Downloader. Download files from the web, with prog bar.

Nice one.

Yup. Just copy frmMain into your app then ref the dll.
Although I would suggest looking at the winsock method, as it's aysnchronous, which has much wider benefits.

Woka
__________________
My .NET Tutorials:
Silverlight Enabled WebPart in WSS

My VB.NET Code Examples:
Create IIS Virtual DirectoryValidate Login Against Active DirectoryAutomatically retrieve Identity field value from inserted DataRow using SQL Server and ADO.NET

My ASP.NET Code Examples:
Login To Website (Forms Authentication)Login To Website (Custom Authentication)

My VB6 Code Projects:
Multithreading In VB6Custom TooltipsMulti Language SupportItem Selector ControlAnnimated Systray IconSimple Effective Graph ControlDownload From WebLiveUpdate, download application updates from the web automaticallySystray Notification MessagesSkin A FormAPI TimerBadger Messenger, an MSN clone that uses the MSN NetworkWokawidgets VB6 Component Suite
Wokawidget is offline   Reply With Quote
Old Mar 14th, 2006, 01:15 PM   #13
Mythrandil
Member
 
Mythrandil's Avatar
 
Join Date: Mar 06
Posts: 55
Mythrandil is on a distinguished road (10+)
Re: VB Downloader. Download files from the web, with prog bar.

Hey,

i know its abit late in the day for this thread but just incase sum1 cares.

I was having trouble getting the winsock version working, constantly getting an error 53, turns out it raises an error if the file you want to download doesnt already exist on your computer

adding a copy where you want to download gets around this but seemed like a funny thing to raise an error about. It downloads and overwrites existing file anyway.(might want to add user warning/input to this) :P
Mythrandil is offline   Reply With Quote
Old Mar 14th, 2006, 05:24 PM   #14
Wokawidget
Super Moderator
 
Wokawidget's Avatar
 
Join Date: Nov 01
Location: Headingly Occupation: Classified
Posts: 9,589
Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)
Re: VB Downloader. Download files from the web, with prog bar.

That is true, but i didn't want my code automatically overwriting files
You can add this code that deletes the old file in your UI code...

Woka
__________________
My .NET Tutorials:
Silverlight Enabled WebPart in WSS

My VB.NET Code Examples:
Create IIS Virtual DirectoryValidate Login Against Active DirectoryAutomatically retrieve Identity field value from inserted DataRow using SQL Server and ADO.NET

My ASP.NET Code Examples:
Login To Website (Forms Authentication)Login To Website (Custom Authentication)

My VB6 Code Projects:
Multithreading In VB6Custom TooltipsMulti Language SupportItem Selector ControlAnnimated Systray IconSimple Effective Graph ControlDownload From WebLiveUpdate, download application updates from the web automaticallySystray Notification MessagesSkin A FormAPI TimerBadger Messenger, an MSN clone that uses the MSN NetworkWokawidgets VB6 Component Suite
Wokawidget is offline   Reply With Quote
Old Mar 15th, 2006, 04:30 AM   #15
Mythrandil
Member
 
Mythrandil's Avatar
 
Join Date: Mar 06
Posts: 55
Mythrandil is on a distinguished road (10+)
Re: VB Downloader. Download files from the web, with prog bar.

Quote:
Originally Posted by Wokawidget
That is true, but i didn't want my code automatically overwriting files
You can add this code that deletes the old file in your UI code...

Woka
yes ofc.

however from my understanding it does the opposite

in the download class module:

If Dir(mstrLocalPath & GetFilename(mstrRemoteFile)) = vbNullString Then
Err.Raise 53

means an error is raised if what you want to dl doesnt exist on local drive, surely should be the opposite ???

If Dir(mstrLocalPath & GetFilename(mstrRemoteFile)) <> vbNullString Then
Err.Raise (overrite error)
Mythrandil is offline   Reply With Quote
Old Mar 21st, 2006, 04:57 AM   #16
Wokawidget
Super Moderator
 
Wokawidget's Avatar
 
Join Date: Nov 01
Location: Headingly Occupation: Classified
Posts: 9,589
Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)
Re: VB Downloader. Download files from the web, with prog bar.

Bad woka *slap*

Yes, you are correct

Woof
__________________
My .NET Tutorials:
Silverlight Enabled WebPart in WSS

My VB.NET Code Examples:
Create IIS Virtual DirectoryValidate Login Against Active DirectoryAutomatically retrieve Identity field value from inserted DataRow using SQL Server and ADO.NET

My ASP.NET Code Examples:
Login To Website (Forms Authentication)Login To Website (Custom Authentication)

My VB6 Code Projects:
Multithreading In VB6Custom TooltipsMulti Language SupportItem Selector ControlAnnimated Systray IconSimple Effective Graph ControlDownload From WebLiveUpdate, download application updates from the web automaticallySystray Notification MessagesSkin A FormAPI TimerBadger Messenger, an MSN clone that uses the MSN NetworkWokawidgets VB6 Component Suite
Wokawidget is offline   Reply With Quote
Old Apr 21st, 2007, 04:04 AM   #17
Aeric
Junior Member
 
Aeric's Avatar
 
Join Date: Nov 06
Posts: 27
Aeric is an unknown quantity at this point (<10)
Re: VB Downloader. Download files from the web, with prog bar.

Thanks Woka. Just what I am looking for.
Aeric is offline   Reply With Quote
Old Jul 16th, 2007, 06:03 PM   #18
isnoend07
PowerPoster
 
isnoend07's Avatar
 
Join Date: Feb 07
Posts: 2,850
isnoend07 has a spectacular aura about (125+)isnoend07 has a spectacular aura about (125+)
Re: VB Downloader. Download files from the web, with prog bar.

Quote:
Originally Posted by TheVader
Nice code, worked fine for me in the IDE. But when I compiled both files (vbWebDownload.dll and DemoDownloadApp.exe) the app didn't work anymore. When trying to download a file the app hangs and after a while says 'Download aborted. Resource not found.' Without error handler it gave me a 'Object variable or With block variable not set' error and an Automation error. Does this happen with anyone else when the app is compiled?
Hope i can get an answer to this old thread. I am having the same problem works good in ide but compiled exe gives me the same error you stated:
download aborted resource not found
Did you ever get a fix?
isnoend07 is offline   Reply With Quote
Old Jul 31st, 2007, 05:03 AM   #19
amolt
Lively Member
 
amolt's Avatar
 
Join Date: Aug 06
Location: INDIA
Posts: 70
amolt is an unknown quantity at this point (<10)
Re: VB Downloader. Download files from the web, with prog bar.

Hi WOKA,

I used your vbDownloader project using OLE and it works great for me!!
Thanks for that!!!!

But though there is a big problem that How can I use it to download multiple files from my URL?
I'm using VB6 and downloading Images from my URL. And I need to download multiple files at the same time the process started for any file.

As I'm not able to understand how to use the OLE Interfaces I request for the resources to understand that properly and useful for Development.

Waiting for reply ...

Thanks ,,
AmolT.
amolt is offline   Reply With Quote
Old Jul 31st, 2007, 05:10 AM   #20
Wokawidget
Super Moderator
 
Wokawidget's Avatar
 
Join Date: Nov 01
Location: Headingly Occupation: Classified
Posts: 9,589
Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)
Re: VB Downloader. Download files from the web, with prog bar.

You need to use the Download Code + Winsock download from my 1st post and create multiple downlaod classes...or combine my multithreading code with the OLE downloading code.

Personally I would go for the 1st option as this is already async.

Woka
__________________
My .NET Tutorials:
Silverlight Enabled WebPart in WSS

My VB.NET Code Examples:
Create IIS Virtual DirectoryValidate Login Against Active DirectoryAutomatically retrieve Identity field value from inserted DataRow using SQL Server and ADO.NET

My ASP.NET Code Examples:
Login To Website (Forms Authentication)Login To Website (Custom Authentication)

My VB6 Code Projects:
Multithreading In VB6Custom TooltipsMulti Language SupportItem Selector ControlAnnimated Systray IconSimple Effective Graph ControlDownload From WebLiveUpdate, download application updates from the web automaticallySystray Notification MessagesSkin A FormAPI TimerBadger Messenger, an MSN clone that uses the MSN NetworkWokawidgets VB6 Component Suite
Wokawidget is offline   Reply With Quote
Old Dec 9th, 2007, 08:32 PM   #21
grrmisfit
New Member
 
Join Date: Dec 07
Posts: 2
grrmisfit is an unknown quantity at this point (<10)
Re: VB Downloader. Download files from the web, with prog bar.

i know this is an old thread but i just came across it. using the non winsock version it works just as i need it to but the issue i have is what if we dont know the file name to be used? like getting files from a php page? the filename is unkown thus no idea what to save it as
grrmisfit is offline   Reply With Quote
Old Dec 10th, 2007, 05:07 AM   #22
Wokawidget
Super Moderator
 
Wokawidget's Avatar
 
Join Date: Nov 01
Location: Headingly Occupation: Classified
Posts: 9,589
Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)
Re: VB Downloader. Download files from the web, with prog bar.

How can the filename be unknown???
Just save it as a tempt file name then? make one up.

woka
__________________
My .NET Tutorials:
Silverlight Enabled WebPart in WSS

My VB.NET Code Examples:
Create IIS Virtual DirectoryValidate Login Against Active DirectoryAutomatically retrieve Identity field value from inserted DataRow using SQL Server and ADO.NET

My ASP.NET Code Examples:
Login To Website (Forms Authentication)Login To Website (Custom Authentication)

My VB6 Code Projects:
Multithreading In VB6Custom TooltipsMulti Language SupportItem Selector ControlAnnimated Systray IconSimple Effective Graph ControlDownload From WebLiveUpdate, download application updates from the web automaticallySystray Notification MessagesSkin A FormAPI TimerBadger Messenger, an MSN clone that uses the MSN NetworkWokawidgets VB6 Component Suite
Wokawidget is offline   Reply With Quote
Old Dec 10th, 2007, 10:50 AM   #23
grrmisfit
New Member
 
Join Date: Dec 07
Posts: 2
grrmisfit is an unknown quantity at this point (<10)
Re: VB Downloader. Download files from the web, with prog bar.

cause you dont know what file your grabbing. its a php script and by entering in a random number it sends you a file but it could be a jpg gif you just dont know. so what im basicly looking to do is send the link then using a for loop on a set number range to enter in the numbers i want. then it download the file. i tried making use of the internet controls but it works just like if i was using a webbrowser and some files like jpg get opened within the browser instead. if the download box would just open for all files i could easily use api to manipulate the box
grrmisfit is offline   Reply With Quote
Old Oct 4th, 2008, 03:26 PM   #24
EmbajadorMX
New Member
 
Join Date: Oct 08
Posts: 7
EmbajadorMX is an unknown quantity at this point (<10)
Re: VB Downloader. Download files from the web, with prog bar.

Dear Woka,

Just what I was looking for, GREAT !!!

As Mythrandil, when I run the code I got error 53, I'm looking to solve this as he posted.

But I have one question about the license of this code... Can I use it royalty free? what kind of license does it has?

Thank you !
EmbajadorMX is offline   Reply With Quote
Old Oct 6th, 2008, 08:57 AM   #25
kleinma
Moderator.NET
 
kleinma's Avatar
 
Join Date: Nov 01
Location: NJ - USA (Near NYC)
Posts: 22,482
kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)
Re: VB Downloader. Download files from the web, with prog bar.

error 53 is usually a file not found error.
__________________
Using VB.NET 2010/.NET 2.0 through 4.0 * Please mark you thread resolved using the Thread Tools above
PLEASE INDICATE WHAT VERSION OF VB YOU USE!!!!!!!!!!!
* If you found a post useful then please Rate it! * DO NOT PM ME WITH LINKS TO YOUR THREADS FOR ANSWERS PLEASE!

Code Bank:Manipulate HTML Page content in the Web Browser Control from VB - Drag Drop from Windows into Win Form - Launch new default browser instance to open URL - Display Internet Image in Picturebox - Download Files From Web With Progress Bar - IP Textbox User Control - Installing .NET Framework with INNO Setup
ZerosAndTheOne.com
-=Matt=-
kleinma is offline   Reply With Quote
Old Oct 6th, 2008, 09:58 AM   #26
EmbajadorMX
New Member
 
Join Date: Oct 08
Posts: 7
EmbajadorMX is an unknown quantity at this point (<10)
Talking Re: VB Downloader. Download files from the web, with prog bar.

Thank you kleinma!

I see you are a moderator in this group. Please tell me about the licence of the code found on this forum. Can I use that code freely?
EmbajadorMX is offline   Reply With Quote
Old Oct 6th, 2008, 10:05 AM   #27
Wokawidget
Super Moderator
 
Wokawidget's Avatar
 
Join Date: Nov 01
Location: Headingly Occupation: Classified
Posts: 9,589
Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)
Re: VB Downloader. Download files from the web, with prog bar.

Hi,

That's correct. File not found. What line is this happening on?

You can use all my code posted on VBF for free.

If you want to add me into the "about" section of your app then that's a bonus but not essential

Woka
__________________
My .NET Tutorials:
Silverlight Enabled WebPart in WSS

My VB.NET Code Examples:
Create IIS Virtual DirectoryValidate Login Against Active DirectoryAutomatically retrieve Identity field value from inserted DataRow using SQL Server and ADO.NET

My ASP.NET Code Examples:
Login To Website (Forms Authentication)Login To Website (Custom Authentication)

My VB6 Code Projects:
Multithreading In VB6Custom TooltipsMulti Language SupportItem Selector ControlAnnimated Systray IconSimple Effective Graph ControlDownload From WebLiveUpdate, download application updates from the web automaticallySystray Notification MessagesSkin A FormAPI TimerBadger Messenger, an MSN clone that uses the MSN NetworkWokawidgets VB6 Component Suite

Last edited by Wokawidget; Oct 6th, 2008 at 12:14 PM.
Wokawidget is offline   Reply With Quote
Old Oct 6th, 2008, 10:09 AM   #28
kleinma
Moderator.NET
 
kleinma's Avatar
 
Join Date: Nov 01
Location: NJ - USA (Near NYC)
Posts: 22,482
kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)kleinma has much to be proud of (1500+)
Re: VB Downloader. Download files from the web, with prog bar.

It is always good to give people credit where credit is due.

So as woka says, he offers his code up for free for anyone to use because he is a nice guy. So if you use his code and it saves you a lot of time, its always nice to give him a little credit in your about screen or readme file.
__________________
Using VB.NET 2010/.NET 2.0 through 4.0 * Please mark you thread resolved using the Thread Tools above
PLEASE INDICATE WHAT VERSION OF VB YOU USE!!!!!!!!!!!
* If you found a post useful then please Rate it! * DO NOT PM ME WITH LINKS TO YOUR THREADS FOR ANSWERS PLEASE!

Code Bank:Manipulate HTML Page content in the Web Browser Control from VB - Drag Drop from Windows into Win Form - Launch new default browser instance to open URL - Display Internet Image in Picturebox - Download Files From Web With Progress Bar - IP Textbox User Control - Installing .NET Framework with INNO Setup
ZerosAndTheOne.com
-=Matt=-
kleinma is offline   Reply With Quote
Old Oct 6th, 2008, 09:11 PM   #29
EmbajadorMX
New Member
 
Join Date: Oct 08
Posts: 7
EmbajadorMX is an unknown quantity at this point (<10)
Re: VB Downloader. Download files from the web, with prog bar.

Thank you Woka!

Of course I'll credit you on my project.

About the error that raises every time I try to download a file, let me explain:

Every time I click the "get file info" button, i got a success message, telling me the size of the file.

Every time I click the "download file" button the application raises error 53, telling me that the file doesn't exist... that is correct because is the first time I try to download it.

I see the error raises on the OpenFile() subroutine, but I don't know how to fix it. Would you please help me, dear Woka? If you try to replicate this behaivor you must delete the file in the download directory, because if it exists before the download begins and no error will be raised.

Thank you for your time!
EmbajadorMX is offline   Reply With Quote
Old Oct 7th, 2008, 05:13 AM   #30
Wokawidget
Super Moderator
 
Wokawidget's Avatar
 
Join Date: Nov 01
Location: Headingly Occupation: Classified
Posts: 9,589
Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)
Re: VB Downloader. Download files from the web, with prog bar.

np
Which line is this happening on?
Which downloader project is this?
What file is it trying to open?
Does the path exist?

Woka
__________________
My .NET Tutorials:
Silverlight Enabled WebPart in WSS

My VB.NET Code Examples:
Create IIS Virtual DirectoryValidate Login Against Active DirectoryAutomatically retrieve Identity field value from inserted DataRow using SQL Server and ADO.NET

My ASP.NET Code Examples:
Login To Website (Forms Authentication)Login To Website (Custom Authentication)

My VB6 Code Projects:
Multithreading In VB6Custom TooltipsMulti Language SupportItem Selector ControlAnnimated Systray IconSimple Effective Graph ControlDownload From WebLiveUpdate, download application updates from the web automaticallySystray Notification MessagesSkin A FormAPI TimerBadger Messenger, an MSN clone that uses the MSN NetworkWokawidgets VB6 Component Suite
Wokawidget is offline   Reply With Quote
Old Oct 8th, 2008, 09:50 AM   #31
EmbajadorMX
New Member
 
Join Date: Oct 08
Posts: 7
EmbajadorMX is an unknown quantity at this point (<10)
Re: VB Downloader. Download files from the web, with prog bar.

Hi Woka!

The project is:
"Downloader and Winsock" located at http://www.vbforums.com/showthread.p...hreadid=310235
Which line is happening on: is on the sub OpenFile() on Download.cls
What file is trying to open: I really don´t know, because no file have been downloaded yet
Does the path Exist: yes, it exists.

I hope you can help me solve this.

Thank you!!!
EmbajadorMX is offline   Reply With Quote
Old Oct 9th, 2008, 03:11 PM   #32
EmbajadorMX
New Member
 
Join Date: Oct 08
Posts: 7
EmbajadorMX is an unknown quantity at this point (<10)
Re: VB Downloader. Download files from the web, with prog bar.

Dear Woka It´s WORKING!!

I understand what´s going on. I´ve solved, now it´s working!

It downloads files asynchrously! you have done a great work. Thank you!!!
EmbajadorMX is offline   Reply With Quote
Old Oct 13th, 2008, 12:07 PM   #33
EmbajadorMX
New Member
 
Join Date: Oct 08
Posts: 7
EmbajadorMX is an unknown quantity at this point (<10)
Re: VB Downloader. Download files from the web, with prog bar.

Hi Woka!

I have one more question related to the proyect Downloader and Winsock located at http://www.vbforums.com/showthread.p...hreadid=310235

The download works ok, now I made the call from a new form inside the same project, but the connection can´t be made. I created a new object "download" and applied it´s methods, It starts the connection but It can´t success.

How the download object must be used from another form within the project?

Thank you for your time!
EmbajadorMX is offline   Reply With Quote
Old Oct 14th, 2008, 05:01 AM   #34
Wokawidget
Super Moderator
 
Wokawidget's Avatar
 
Join Date: Nov 01
Location: Headingly Occupation: Classified
Posts: 9,589
Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)Wokawidget is a jewel in the rough (300+)
Re: VB Downloader. Download files from the web, with prog bar.


Using the code on diff forms doesnt seem to be the problem.

Why does it not connect? Do you get an error?

Woka
__________________
My .NET Tutorials:
Silverlight Enabled WebPart in WSS

My VB.NET Code Examples:
Create IIS Virtual DirectoryValidate Login Against Active DirectoryAutomatically retrieve Identity field value from inserted DataRow using SQL Server and ADO.NET

My ASP.NET Code Examples:
Login To Website (Forms Authentication)Login To Website (Custom Authentication)

My VB6 Code Projects:
Multithreading In VB6Custom TooltipsMulti Language SupportItem Selector ControlAnnimated Systray IconSimple Effective Graph ControlDownload From WebLiveUpdate, download application updates from the web automaticallySystray Notification MessagesSkin A FormAPI TimerBadger Messenger, an MSN clone that uses the MSN NetworkWokawidgets VB6 Component Suite
Wokawidget is offline   Reply With Quote
Old Oct 14th, 2008, 01:28 PM   #35
EmbajadorMX
New Member
 
Join Date: Oct 08
Posts: 7
EmbajadorMX is an unknown quantity at this point (<10)
Re: VB Downloader. Download files from the web, with prog bar.

Upss...!

It´s my failure... I tried to connect to a site which was up at certain time, but for some reason this site went down exactly when I tried the connection using the new form. Your program works correctly.

Thank you for all your support Woka!
EmbajadorMX is offline   Reply With Quote
Reply

Go Back   VBForums > VBForums CodeBank > CodeBank - Visual Basic 6 and earlier


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -5. The time now is 05:39 AM.





Acceptable Use Policy

Internet.com
The Network for Technology Professionals

Search:

About Internet.com

Legal Notices, Licensing, Permissions, Privacy Policy.
Advertise | Newsletters | E-mail Offers

Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.