Jury Posted October 6, 2013 Share Posted October 6, 2013 (edited) I've tried this again and this doesn't seem to work and I'm not sure what is the best way to do this or that there may be hidden problems. Depending on which of three databases the user has chosen (each having its own WindowTitle) I want to attach to that WindowTitle. Local $oIE = _IEAttach("Deportation Decisions") If _IEErrorNotify() Then Local $oIE = _IEAttach("Refugee/Protection Decisions") EndIf If _IEErrorNotify() Then Local $oIE = _IEAttach("Residence Decisions") EndIf Thanks, jury Edited October 6, 2013 by Jury Link to comment Share on other sites More sharing options...
Danp2 Posted October 6, 2013 Share Posted October 6, 2013 (edited) Calling _IEErrorNotify() is not the proper way to check if the _IEAttach was successfully. You need to be checking the value of @error. Depending on which of three databases the user has chosen (each having its own WindowTitle) I want to attach to that WindowTitle. How does the user specify the desired database? Edited October 6, 2013 by Danp2 Latest Webdriver UDF Release Webdriver Wiki FAQs Link to comment Share on other sites More sharing options...
Jury Posted October 6, 2013 Author Share Posted October 6, 2013 Thanks Danp2 - they click on a link on the page which navigates (i.e. doesn't open a new window) to the chosen database. Link to comment Share on other sites More sharing options...
Danp2 Posted October 6, 2013 Share Posted October 6, 2013 Will the desired tab always be active when you call your routine? If so, then perhaps >this function will help. Latest Webdriver UDF Release Webdriver Wiki FAQs Link to comment Share on other sites More sharing options...
Jury Posted October 6, 2013 Author Share Posted October 6, 2013 so I call this function like this? $oIE = _IEGetActiveTab() Link to comment Share on other sites More sharing options...
Danp2 Posted October 6, 2013 Share Posted October 6, 2013 Correct. 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