I have spent several days debugging to locate a problem with the file open dialog box that is presented by an html "file" type.
I am getting a valid handle to the control on the file open dialog, but, when winClicker attempts to (ultimately) use set_text, the text is not put into the combo box text on the dialog box, and the message is never acknowledged, leaving the Open File dialog sitting there. The code is as follows: adoc = $ie.frame("main").image(:src, "https://alinea.inmar.com/alinea/images/adddocument.gif") sleep 2 adoc.click_no_wait sleep 2 modal = $ie.modal_dialog assert_not_nil modal $path = "C\:\\LogTest.txt" puts "starting autoit" $autoit = WIN32OLE.new("AutoItX3.Control") sleep 1 ffld = modal.fileField(:name, "selectDoc") ffld.set($path) success = $autoit.WinWait("Choose file", "", 10) if success == 0 puts "Failed to find Choose file" end $autoit.WinActivate("Choose file") $autoit.Send("{TAB 3}{ENTER}") modal.text_field(:name, "Subject").set("Test Subject") modal.select_list(:id,"LB1").set("hward") modal.select_list(:id,"LB1").fire_event("onDblClick") modal.button(:value, "Add Document").click sleep 2 modal = $ie.modal_dialog modal.button(:value, "Close").click The error message about not finding "Choose file" occurs frequently and the autoit code appears to do nothing. The fields in the modal dialog under the File Open will work as long as a file name is manually entered. I was able, one time, to get autoit to push something into the File Name field, but I have not been able to get it to work again. Is there a way to get this process to complete? --------------------------------------------------------------------- Posted via Jive Forums http://forums.openqa.org/thread.jspa?threadID=5403&messageID=15064#15064 _______________________________________________ Wtr-general mailing list Wtr-general@rubyforge.org http://rubyforge.org/mailman/listinfo/wtr-general