[HELP] Download and replace file
If you need help with a project or need to know how to do something specific in VB.NET then please ask your questions in here.
Forum rules
Please LOCK your topics once you have found the solution to your question so we know you no longer require help with your query.
Please LOCK your topics once you have found the solution to your question so we know you no longer require help with your query.
10 posts
Page 1 of 1
hi i got this code
My.Computer.Network.DownloadFile("", "" )
how do i make it replace the file because it gives me errors if the file already exsists, can i make it so it downlods and replace that file, please help
My.Computer.Network.DownloadFile("", "" )
how do i make it replace the file because it gives me errors if the file already exsists, can i make it so it downlods and replace that file, please help
With the same code you have more options, you have the server username and password from the server you are downloading the file, showUI, timeout and overwrite.
Code: Select all
http://msdn.microsoft.com/en-us/library ... 90%29.aspxMy.Computer.Network.DownloadFile("download location", "where you want to save it", "user", "pass", False, 100, True)
My name is Tom | Visit my blog where I post new content every day! Tom's Daily Blog | MineCraft is awesome!
do i have to put a user, pass because it downloaded files earlier without a user and pass?
You could just put , , instead of using a user and a pass and leave it blank, look in Visual studio if it says in the description that comes up when you type "Username" above your code just put , then it will change to pass then put , then it will say Show UI you can just put True or False it gives a description as you're typing the code out
My name is Tom | Visit my blog where I post new content every day! Tom's Daily Blog | MineCraft is awesome!
i tried this and it gave me errors i also tried doing "", "" also errors
This should work:
Code: Select all
The "", "" is user and pass default value, the False is showUI and 100 is connection timeout default and True is to overwrite the file My.Computer.Network.DownloadFile("download location", "where you want to save it", "", "", False, 100, True)
My name is Tom | Visit my blog where I post new content every day! Tom's Daily Blog | MineCraft is awesome!
I haven't done that for awhile sorry you will need someone else to help.
Is it replacing the file now though?
Is it replacing the file now though?
My name is Tom | Visit my blog where I post new content every day! Tom's Daily Blog | MineCraft is awesome!
10 posts
Page 1 of 1
Copyright Information
Copyright © Codenstuff.com 2020 - 2023