Hayseed Posted July 3 Posted July 3 Open url in default browser and wait till page loaded. I have been to this site many times but yet to see this answered, so have joined to expand the question. My default browser is MS Edge. Certainly not my favourite browser, but it is a club computer. The web page I am opening is Bridgewebs which blocks Internet explorer. Using Autoit script I open the page and ping to confirm it has opened before proceeding with my script. This has proved unreliable with the script proceeding before the page is able to respond to the script. ShellExecute("https://www.bridgewebs.com/cgi-bin/bwor/bw.cgi?pid=upload_menu&wd=1&club=motueka") Func _local2() Local $PID = ping("https://www.bridgewebs.com/cgi-bin/bwor/bw.cgi?pid=upload_menu&wd=1&club=motueka") If $PID = 0 Then Do Sleep(10) Until ping("https://www.bridgewebs.com/cgi-bin/bwor/bw.cgi?pid=upload_menu&wd=1&club=motueka") <> 0 ; If yes then end loop Else EndIf EndFunc Any alternative wait scripts or should this method work? Thanks
argumentum Posted July 3 Posted July 3 16 minutes ago, Hayseed said: should this method work? Nope. None of that should work. So you play cards ? What is your final goal to be achieved with code ? Follow the link to my code contribution ( and other things too ). FAQ - Please Read Before Posting.
Hayseed Posted July 3 Author Posted July 3 Thank you for your response. Bridgewebs allows independent posting of a session results which requires a login. I could simply put a long sleep in the script but this has caused dangerous uncontrollable variance of the script when the webpage has taken longer to open than expected. And with uploading results at the end of the night, one wants it done in minimal time.
argumentum Posted July 4 Posted July 4 14 minutes ago, Hayseed said: I could simply put a long sleep in the script but this has caused dangerous uncontrollable variance of the script when the webpage has taken longer to open than expected. hmm, maybe Send a Ctrl+A ( to select all text ), then Ctrl+C ( to copy the selected text ) and if "allow for www.bridgewebs.com. If you do not" is in the text, it could be said that the page loaded. Otherwise you'd have to learn how to work with a webdriver. Hayseed 1 Follow the link to my code contribution ( and other things too ). FAQ - Please Read Before Posting.
Hayseed Posted July 4 Author Posted July 4 Yes, I just looked at webdriver, new to me and not keen, at least this week. You have given me confirmation 'ping' is not working and another option to explore. Many thanks for that. I will post further as time allows. argumentum 1
Moderators Melba23 Posted July 4 Moderators Posted July 4 Moved to the appropriate forum. Moderation Team Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area
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