I'm new with AHK here and just started playing around with selenium automation.
I tried to fill/send value to 1 of the combobox in the webform, but seems unable to since my script didn't return any based on the ID in the script. As I tried to count the result only return with 0.
Can I get a guidance here where did I go wrong? Thank you heaps.
Below is the code inspect of the combobox:
Code: Select all
<input id="sys_display.incident.u_service_portfolio" name="sys_display.incident.u_service_portfolio" aria-labelledby="label.incident.u_service_portfolio" type="search" autocomplete="off" autocorrect="off" value="" data-type="ac_reference_input" data-completer="AJAXReferenceCompleter" data-dependent="" data-dependent-value="" data-ref-qual="" data-ref="incident.u_service_portfolio" data-ref-key="null" data-ref-dynamic="false" data-name="u_service_portfolio" data-table="spm_service_portfolio" class="form-control element_reference_input" style="; " spellcheck="false" onfocus="if (!this.ac) addLoadEvent(function() {var e = gel('sys_display.incident.u_service_portfolio'); if (!e.ac) new AJAXReferenceCompleter(gel('sys_display.incident.u_service_portfolio'), 'incident.u_service_portfolio', '', ''); e.ac.onFocus();})" aria-required="false" role="combobox" aria-autocomplete="list" aria-owns="AC.incident.u_service_portfolio" aria-expanded="false" title="" aria-invalid="false">
Code: Select all
driver:= ComObjCreate("Selenium.ChromeDriver") ; I get error here "THE system cannot find the file specified"
driver.get("https yesassist.service-now.com /incident.do?sys_id=-1&sysparm_query=active=true&sysparm_stack=incident_list.do?sysparm_query=active=true") Broken Link for safety
MsgBox, % driver.Window.Title "`n" driver.Url
searchbox_count:=driver.findElementsByID("sys_display.incident.u_service_portfolio").Count()
MsgBox, %searchbox_count%