1 Attachment(s)
help me please quick on webbrowser
hello i am vb6 user and there is a site with allows you to choose am image then upload it i have loaded with webbrowser and m using this but it just dont work
WebBrowser1.Document.getelementbyid("media").Value = "C:\Users\junior\Desktop\as.PNG"
help me plz how can i upload imageAttachment 105733
Re: help me please quick on webbrowser
That by itself wont upload. That only puts the path in a variable but you need to send it by clicking on a button probably. You need to post more of the relevant code.
Re: help me please quick on webbrowser
then can u write the code how is it done?
Re: help me please quick on webbrowser
No I cannot. You have the code. The code I am referring to is the same code you used for this:
WebBrowser1.Document.getelementbyid("media").Value = "C:\Users\junior\Desktop\as.PNG"
If you knew the name to look for is "media" then use the same code where you got that name from and post it
Re: help me please quick on webbrowser
but its not working.......... everyitime i see new messages in email from vbforums i expect to get my answer plz help
Re: help me please quick on webbrowser
I know it's not working. You put "C:\Users\junior\Desktop\as.PNG" in a variable on a web page document. You have that document in your WebBrowser and since you knew the name of the variable which is "media" then you must have seen the code or how else did you know the name. So, if you know the name of the variable then I am asking you to post the code that contains that element "media" in it but I need to see more of it so I can find the button name that you need to click on to upload your image
Re: help me please quick on webbrowser
here is the code <input type="file" name="media" value="" width="40">
Re: help me please quick on webbrowser
You need to code the submit button.
Re: help me please quick on webbrowser
you have a duplicate thread on this topic, where i have already replied
file input elements can not be automated in vb6, this is a deliberate browser security precaution, to prevent malware from doing the same
you would need to post the file using separate code from the webpage, but using information from the webpage
Re: help me please quick on webbrowser
Quote:
Originally Posted by
kushaladhikari12
here is the code <input type="file" name="media" value="" width="40">
I asked for more of the code so I can find the button in order for you to submit your request. You only posted the part which contains the "media"
You don't appear to understand what is needed to do what you want
Re: help me please quick on webbrowser
Post the WHOLE HTML source of the page please.