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
MS Excel 2007 & PDF - Exporting to PDF takes long hours!
ASA 8.3 NAT Configuration
Extract / Create thumbnails (1st page) for office documents using PHP on Windows or Linux/Mac server
Selecting Multiple Fields Using MAX
DNS Search List appending to all nebios / dns names
Urgent: How to locate the current in use ID file in Lutus Notes 7
Can't install wifi printer MX870
difference between AD integrated dns server and dns server
Respose time slow
Using Bash command in Perl Script