Microsoft
Software
Hardware
Network
Question : Find button on form
Hi,
I'm trying to find a button on a webpage, so I can click it. First I find the form where it's contained.
I use this code:
final HtmlButton newDocButton = Form1.getButtonByName("cmd
NewDoc");
assertNotNull("newDocButto
n doesn't return anything", newDocButton);
System.out.println("Found newDocButton.");
newDocButton.click();
But I get this error message:
Exception: com.gargoylesoftware.htmlu
nit.Elemen
tNotFoundE
xception: elementName=[button] attributeName=[name] attributeValue=[cmdNewDoc]
In what other way can I go looking for it?
Thank you,
Ana
Related Solutions:
HtmlUnit to test webpages
Answer : Find button on form
try:
HtmlSubmitInput button = form.getInputByName("cmdNe
wDoc");
Random Solutions
NAT setting and vmware
Windows firewall will not start
Convert C#? to VB / vb.script
Public Desktop Icons not showing in RDP sessions
Configure TFS 2010 with Sharepoint 2010
Windows XP computer keeps locking up
worst thing to happen if wireless does not have pw?
Fully Automatic dental milling machines
Sharepoint 2010 - 2 domains and non domain users
MacBook Stuck on Shut-Down