-
Apr 29th, 2018, 02:04 AM
#1
Thread Starter
New Member
upload file in host
Hi, please help me upload file to my hosting
Last edited by Shaggy Hiker; Apr 29th, 2018 at 09:46 AM.
Reason: Removed links
-
Apr 29th, 2018, 03:09 AM
#2
Fanatic Member
Re: upload file in host
you can search winsock upload .or winhttp.
-
Apr 29th, 2018, 09:47 AM
#3
Re: upload file in host
Those links didn't seem useful to the question. If you have an issue with uploading a file to your hosting site, what is the issue? The files don't matter.
My usual boring signature: Nothing
-
May 5th, 2018, 05:22 AM
#4
Thread Starter
New Member
Re: upload file in host
Please complete the following source for uploading zip files to your hosting
Code:
Private Sub Command1_Click()
On Error Resume Next
WebBrowser1.Silent = True
WebBrowser1.Navigate ("http://address/CMD_LOGIN")
Do While WebBrowser1.ReadyState <> "4"
DoEvents
Loop
WebBrowser1.Document.Forms(0).elements("username").Value = "username"
WebBrowser1.Document.Forms(0).elements("password").Value = "password"
WebBrowser1.Document.Forms(0).submit
WebBrowser1.Navigate ("http://address/HTM_FILE_UPLOAD?path=/")
'Do While WebBrowser1.ReadyState <> "4"
' DoEvents
' Loop
End Sub
Last edited by si_the_geek; May 7th, 2018 at 08:27 AM.
Reason: replaced username etc
-
May 6th, 2018, 04:16 PM
#5
Re: upload file in host
http://www.vbforums.com/showthread.p...65#post4526665
have a look at the example to see if it can suit your requirements
i do my best to test code works before i post it, but sometimes am unable to do so for some reason, and usually say so if this is the case.
Note code snippets posted are just that and do not include error handling that is required in real world applications, but avoid On Error Resume Next
dim all variables as required as often i have done so elsewhere in my code but only posted the relevant part
come back and mark your original post as resolved if your problem is fixed
pete
-
May 7th, 2018, 07:15 AM
#6
Re: upload file in host
I hope those aren't your actual login credientials you posted there. Someone could easily take them and use them nefariously. I'd get those blanked out as quick as you can. I've also notified the mods in case they can get to it before you do./
-tg
-
May 8th, 2018, 02:39 AM
#7
Thread Starter
New Member
Re: upload file in host
Hello, please describe how to upload the file on http://up2www.com/ using the WebBrowser
Code:
Private Sub Command1_Click()
On Error Resume Next
WebBrowser1.Silent = True
WebBrowser1.Navigate ("http://address/CMD_LOGIN")
Do While WebBrowser1.ReadyState <> "4"
DoEvents
Loop
WebBrowser1.Document.Forms(0).elements("username").Value = "username"
WebBrowser1.Document.Forms(0).elements("password").Value = "password"
WebBrowser1.Document.Forms(0).submit
WebBrowser1.Navigate ("http://address/HTM_FILE_UPLOAD?path=/")
'Do While WebBrowser1.ReadyState <> "4"
' DoEvents
' Loop
End Sub
-
May 8th, 2018, 05:23 AM
#8
Re: upload file in host
i doubt it can be done just with the webbrowser control, file inputs are, deliberately, not able to be automated, which is why i developed the work around linked to above, which works in with the webbrowser control or internet explorer object
i do my best to test code works before i post it, but sometimes am unable to do so for some reason, and usually say so if this is the case.
Note code snippets posted are just that and do not include error handling that is required in real world applications, but avoid On Error Resume Next
dim all variables as required as often i have done so elsewhere in my code but only posted the relevant part
come back and mark your original post as resolved if your problem is fixed
pete
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|