ausssieautomate Posted May 11, 2009 Share Posted May 11, 2009 Heyas, I am trying to pull text from a webpage and paste it into an excel spreadsheet formatting purposes. I can use the following commands just fine. WindowActivate("asdf") Send("^a") Send("^c") $Excel1 = ClipGet() From there I paste in the results good shortcut it doesn't always work though, so I was thinking of using something a little more refined the _IEBodyReadText command. Here's what I done WindowActivate("asdf") $oIE = _IEAttach("asdf") -ALSO- _IEAttach("asdf", "text") -ALSO- _IEAttach("asdf", "WindowTitle") excel1 = _IEBodyReadText($oIE) msgbox(0, "jkl;", $excel1) The msgbox keeps displaying the result as zero. Any ideas? Frequent sufferer of ID10T Syndrome and CRAFT (Can't Remember A "BLEEP" Thing) Link to comment Share on other sites More sharing options...
Authenticity Posted May 11, 2009 Share Posted May 11, 2009 Seems like you're doing something wrong or the title is not correct or something else... Take this for example: #include <IE.au3> $_IEErrorNotify = False Dim $oIE Dim $sDocHTML ShellExecute('iexplore', 'http://www.autoitscript.com') Do Sleep(200) $oIE = _IEAttach('autoit script home page') Until Not @error $sDocHTML = _IEDocReadHTML($oIE) ConsoleWrite($sDocHTML & @LF) Link to comment Share on other sites More sharing options...
ausssieautomate Posted May 12, 2009 Author Share Posted May 12, 2009 Hi Authenticity, Cheers mate that got it. Seems like you're doing something wrong or the title is not correct or something else... Take this for example: #include <IE.au3> $_IEErrorNotify = False Dim $oIE Dim $sDocHTML ShellExecute('iexplore', 'http://www.autoitscript.com') Do Sleep(200) $oIE = _IEAttach('autoit script home page') Until Not @error $sDocHTML = _IEDocReadHTML($oIE) ConsoleWrite($sDocHTML & @LF) Frequent sufferer of ID10T Syndrome and CRAFT (Can't Remember A "BLEEP" Thing) 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