IanN1990 Posted October 2, 2011 Posted October 2, 2011 (edited) Heya I am new to site and claim no talent or credit for the following code but i was wondering if someone could help me improve it and make it more proffesional. #include $ie=_IECreate('http://www.bbc.co.uk/iplayer/', 0, 1, 0) _IELoadWait($ie) GUISetState() Do Sleep (250) $ie.document.body.scroll = "NO" $ie.document.body.style.overflow = "hidden" Until GUIGetMsg() = 1 It opens bbc.co.uk in IE and remove the scrollbars, and then loops every 250 mili seconds "to reduce strain on the cpu" to remove it again "incase you have loaded a new webpage. When you close IE you get a error message "Line 2604 (File: "D\Desktop.Internet.exe"): Error: The requested action with this object has failed." So my 2 questions. Is there any way to keep the funcationality of removing the scrollbars while removing the error message and maybe improving the cpu performance? Edited April 14, 2012 by IanN1990
sleepydvdr Posted October 2, 2011 Posted October 2, 2011 How about this: #include<IE.au3> $ie=_IECreate('http://www.bbc.co.uk/iplayer/', 0, 1, 0) _IELoadWait($ie) GUISetState() Do Sleep (250) $ie.document.body.scroll = "NO" $ie.document.body.style.overflow = "hidden" Until NOT ProcessExists("iexplore") #include <ByteMe.au3>
IanN1990 Posted October 2, 2011 Author Posted October 2, 2011 (edited) This code works perfectly, thanks for your fast reply Edited October 2, 2011 by IanN1990
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