bbedon Posted April 1, 2014 Share Posted April 1, 2014 Hi everybody, I'm a novice in AutoIT, but i will try to explain clearly my problem. I try to check a checkbox on a intranet website with different methods but it doesn't work. I alaways have the errors : "--> IE.au3 T3.0-1 Warning from function _IEImgClick, $_IEStatus_NoMatch --> IE.au3 T3.0-1 Warning from function _IEImgClick, $_IEStatus_NoMatch --> IE.au3 T3.0-1 Warning from function _IEImgClick, $_IEStatus_NoMatch --> IE.au3 T3.0-1 Warning from function _IEFormImageClick, $_IEStatus_NoMatch --> IE.au3 T3.0-1 Warning from function _IEFormImageClick, $_IEStatus_NoMatch --> IE.au3 T3.0-1 Warning from function _IEFormImageClick, $_IEStatus_NoMatch" #include <IE.au3> $o_IE = _IECreate () WinSetState(_IEPropertyGet ($o_IE, "hwnd" ), "", @SW_MAXIMIZE ) _IENavigate ($o_IE, "http://si.intranet.corp.sopra/Applications/MP/SuiviQualite/DynamicConso/QSConsolidationCreationPRJ.aspx?CONSODYN=P&ACCESMENUCONSOPROJET=1") MouseClick("left", 397, 171) MouseClick("left", 381, 209) MouseClick("left", 227, 250) Send("{DOWN}") MouseClick("left", 712, 250) MouseClick("left", 190, 444) MouseClick("left", 714, 442) MouseClick("left", 176, 568) MouseClick("left", 176, 592) MouseClick("left", 176, 615) MouseClick("left", 176, 638) MouseClick("left", 176, 662) Send("{DOWN}") MouseClick("left", 735, 690) Sleep(4000) _IELoadWait($o_IE) _IEImgClick($o_IE, "/Res/ico/CheckOn.gif" , "src") _IEImgClick($o_IE, "Sélectionner toutes les lignes" , "alt") _IEImgClick($o_IE, "SELECTIONNER" , "id") _IEFormImageClick($o_IE, "/Res/ico/CheckOn.gif" , "src") _IEFormImageClick($o_IE, "Sélectionner toutes les lignes" , "alt") _IEFormImageClick($o_IE, "SELECTIONNER" , "id") I also try with _IEAction but it doesn't work too. Here the code of the intranet website </style></head> <body onkeydown="return gestionAppuieTouche(event);" onfocus="pageFonctionsPriseFocus();" onscroll="deplacerMessages();" onload="pageFonctionsDeDemarrage();" onunload="pageFonctionsDeFermeture();" onresize="deplacerMessages();"><form name="FormulairePrincipal" id="FormulairePrincipal" action="QSConsolidationCreationPRJ.aspx?CONSODYN=P&ACCESMENUCONSOPROJET=1#ancregrdResultat" method="post" _events="[object Object]"><table width="100%" id="TabRechercheClient" border="0" cellSpacing="0" cellPadding="0"><tbody><tr><td align="left" colSpan="4"><table id="grdResultat" style="width: 100%;" border="0" cellSpacing="2" cellPadding="2"><tbody><tr><td align="center" class="cssTableauEntete" style="width: 10px;"><a onclick="return verifierActionClic(true, false, '');" href="javascript:__doPostBack('grdResultat$ctl01$ctl00','')"> <img name="SELECTIONNER" width="16" title="Sélectionner toutes les lignes" alt="Sélectionner toutes les lignes" src="/Res/ico/CheckOn.gif" border="0" /> </a></td></tr></tbody></table></td></tr></tbody></table></form></body></html> The name of the image which is the chekbox is "SELECTIONNER", i don't know if i need to use the img or the onclick which is just before. Thank you for your help. Best Regards Bastien BEDON Link to comment Share on other sites More sharing options...
Danp2 Posted April 1, 2014 Share Posted April 1, 2014 <a onclick="return verifierActionClic(true, false, '');" href="javascript:__doPostBack('grdResultat$ctl01$ctl00','')"> Does it work if you send a click to this link instead of the image? Latest Webdriver UDF Release Webdriver Wiki FAQs Link to comment Share on other sites More sharing options...
bbedon Posted April 2, 2014 Author Share Posted April 2, 2014 I try like this too : Local $oSubmit = _IEFormElementGetObjByName($o_IE, "SELECTIONNER") _IEAction($oSubmit,"click") I don't know how call the action "onclick". Can you help me ? Thank you for your help Link to comment Share on other sites More sharing options...
Danp2 Posted April 2, 2014 Share Posted April 2, 2014 If the html you posted was complete, then this is the only link on the page and you should be able to use _IELinkClickByIndex to click it. Latest Webdriver UDF Release Webdriver Wiki FAQs Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now