-
Hi all
I got a little problem with my Webbrowser. I want to let it fill out some Webforms by itself. Just the same as an Cookie, but stored in a Database. So how can I send the needet Text to the fields on a Webpage ? I wanna make it possible that my browser do all by itself e.g. fill out username and passwort. I got it work that it fills out normal textboxes and some Comboboxes. But if the Combobox has no Value, it doesnt work. Also I got a problem with the Buttons. If it is an normal button, I can easily click it, but what is the code to click a gif picture if it is the "button" ? Hope anyone can help me coz I´m searching since a long time for a solution for that. For those who didnt understand what I mean:
To fill out a normal Textbox, I use:
Set objinput = webbrowser1.Document.All.tags("input")
objinput(6).Value = "whatever I want"
For a combobox with values:
Set objselect = webbrowser1.Document.All.tags("select")
objselect(0).Value = "an existing value"
For normal buttons:
webbrowser1.Document.Forms(0).Elements(24).Click
(The numbers in the"()" are the numbers of the elements on the Webpage.
Ok, I hope everyone has understod what I mean, and someone can help me with this. Thx for reading this post.
Seeker
P.S. sorry for my bad english
-
tell me , how do u fill textboxes ?
what do u declare of the objinput ?
-
Filling out
Well, as I wrote on my first post:
Set objinput = webbrowser1.Document.All.tags("input")
objinput(6).Value = "whatever I want"
You need a blank form and the webbrowser item. Now, if you want to fill out a Website which only have 3 Textboxes on it, use the code above, and just change the "6" into the number of the box you want to fill. If you wanna fill the first one (counting from the top to the end) you have to change it to "1" and so on.
Greetz
Seeker
-
Code:
Webbrowser1.Navigate "http://www.mysite.com/form.cgi"
WebBrowser1.Document.Forms(0).boxname.Value = "My Text"
WebBrowser1.Document.Forms(0).proceed.Click
'box name and proceed are names of the input box and the submit button.
I hope that's what you were looking for, Gl,
D!m
-
Thx
Thank you for your help. I´ll check this out. This code seems to be that what I was looking for. Thx again for your support :D
Seeker
-
you have helped me also.
but one thing , i have a button that is under a picture
and something with java script
and i cant find its name to click on
very wired
if u can check its the site
isend.cellcom.co.il
and it has two yellow buttons and i cant find the name of them
-
1 Attachment(s)
i have a better idea , here is the source of the page
i need the picture click that does javascript=submitit
i need to run that script with vb
please help
10x
-
The same prob
Hi. As I wrote in the first post, thats exactly what I wanna know, too. I got this problem with the "picture button" too. Well, I´ve tried your tips, but they dont work :( But there MUST be a solution for this. If we can click a normal button, it MUST be possible to click a picture button, too. I have postet on some other forums with this prob, and if I can find a solution, I´ll post it here.
Seeker