saldous Posted March 8, 2007 Posted March 8, 2007 (edited) I would like to launch an IE session using _IECreate, but I want to launch it hidden so the user can't see it, then once launched I want to be able to perform actions on that web page, for example I want to enter some text into an input box and click on a button. How do I go about doing this in a hidden window? I can get it all working fine in a visible one, but I don't want the user to see anything. I think I can create the window hidden using: _IECreate ("http://www.google.co.uk", 0, 0) But how do I perform actions on that page? the problem I see is that I can't use pixel search on a hidden window, I can't click a button on it, I can't even see the hidden window in Task Manager. Edited March 8, 2007 by saldous
DaleHohm Posted March 9, 2007 Posted March 9, 2007 Every IE.au3 example works equally well on an invisible window -- note that NONE of the IE.au3 examples use pixel search. Use the object model - and I hope you're not doing anything nefarious, because I'll regret helping you. Dale Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble
saldous Posted March 9, 2007 Author Posted March 9, 2007 Hi, thanks, I'll give that a try. What I want to go it open a browser, navigate to a page, enter the users login credentials, click the login button and then unhide the window. So the time the user sees it it is already done all the work and on the page I want them to see, I don't want them to see it all happening.
saldous Posted March 9, 2007 Author Posted March 9, 2007 How do I un-hide a hidden IE window? I've tried the @SW_SHOW but it doesn't work on the following: _IECreate ("http://www.google.co.uk", 0, 0)
DaleHohm Posted March 9, 2007 Posted March 9, 2007 _IEAction($oIE, "visible") Dale Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble
saldous Posted March 9, 2007 Author Posted March 9, 2007 oh, ok, thanks. I was looking at _IEPropertySet, no wonder I couldn't figure it out!
DaleHohm Posted March 9, 2007 Posted March 9, 2007 oh, ok, thanks. I was looking at _IEPropertySet, no wonder I couldn't figure it out!Yeah, sorry. _IEAction was created long before _IEPropertySetDale Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble
saldous Posted March 9, 2007 Author Posted March 9, 2007 (edited) Sorry, I have another question... Once the window becomes visible again, how to I set it to OnTop? At the moment it appears behind other open windows. EDIT: Think I got it with: _IEAction($oIE, $GUI_ONTOP) EDIT: Nope, that isn't it! Still need help. EDIT: Got it, WinSetOnTop("Untitled - ", "", 1) Edited March 9, 2007 by saldous
DaleHohm Posted March 9, 2007 Posted March 9, 2007 Get the browser window handle and then you can use standard AutoIt Win* functions on it: $hwnd = _IEPropertyGet($oIE, "hwnd") WinActivate($hwnd) Dale Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble
Bert Posted March 9, 2007 Posted March 9, 2007 ummm...you want to set IE to enter in data...and not let them know about it..... You mind sharing on why one would need to do that? That is reaching toward the hacker side of things, and could be very easily be used for dark stuff... No offence.....but this does seem quite sneaky and dark. The Vollatran project My blog: http://www.vollysinterestingshit.com/
DaleHohm Posted March 9, 2007 Posted March 9, 2007 ummm...you want to set IE to enter in data...and not let them know about it.....You mind sharing on why one would need to do that? That is reaching toward the hacker side of things, and could be very easily be used for dark stuff...No offence.....but this does seem quite sneaky and dark.Asked and answered. See above.Dale Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble
seandisanti Posted March 9, 2007 Posted March 9, 2007 ummm...you want to set IE to enter in data...and not let them know about it.....You mind sharing on why one would need to do that? That is reaching toward the hacker side of things, and could be very easily be used for dark stuff...No offence.....but this does seem quite sneaky and dark.i have a couple of scripts that i made for work that have to do that. we have web resources that require my login, and i don't want the people whose computer i'm using to access them to be able to see my password, not even the length of the password.
saldous Posted March 9, 2007 Author Posted March 9, 2007 That's exactly what I'm trying to do Cameronsdad. I have no interest in hacking and don't get time to play games so I'm not making bots either. I'm simply trying to simplify some work tasks and make it as easy and unintrusive for users as possible.
seandisanti Posted March 9, 2007 Posted March 9, 2007 That's exactly what I'm trying to do Cameronsdad. I have no interest in hacking and don't get time to play games so I'm not making bots either. I'm simply trying to simplify some work tasks and make it as easy and unintrusive for users as possible.one thing that you can do, depending on your comfort level with gui's, is remove the browser window from view completely. there are a few processes i've done at work here, where i've just made gui's to replace the forms that they would use, and navigate the browser completely in the background, as far as the end users are concerned, abstraction is 100%; they think that the program they're using replaced the webpage, rather than hiding it.
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