Sign in to follow this  
Followers 0
therks

Embedded IE and AnimateWindow don't get along

10 posts in this topic

#1 ·  Posted (edited)

So I have this problem, not sure if it's overcome-able, but I hope so. I create an embedded IE object, and toss it in my GUI. Now whenever I use the AnimateWindow function (include found here) to show or hide the window the IE object gets all glitchy looking. Sometimes it goes all white, other times the content just gets all weird looking.

Any ideas if this can be prevented? Or am I just stuck with it?

#include <IE.au3>
#include <_Animatewindow.au3>

$oIE = _IECreateEmbedded()

$gui = GUICreate('', 200, 200)
$bt_Refocus = GUICtrlCreateButton('', -100, 0, 1, 1)
$ob_Main = GUICtrlCreateObj($oIE, 10, 10, 180, 180)
_IENavigate($oIE, 'about:blank')

_IEDocWriteHTML ($oIE, _
    '<body bgcolor="blue" text="white">' & @CRLF & _
    '<button id="closeBtn">Close</button><br/>' & _
    'Click the button to close, or wait for 5 seconds.')
_AnimateWindow($gui, '', 2000, BitOR($WINANI_RIGHTTOLEFT, $WINANI_BOTTOMTOTOP))
GUISetState()


$oCloseObj = _IEGetObjByName($oIE, 'closeBtn')
If Not @error Then
    $oCloseEvt = ObjEvent($oCloseObj, 'closeBtn_')
EndIf

Sleep(5000)

_AnimateWindow($gui, '', 2000, BitOR($WINANI_RIGHTTOLEFT, $WINANI_BOTTOMTOTOP, $WINANI_HIDE))

Func closeBtn_onclick()
    _AnimateWindow($gui, '', 2000, BitOR($WINANI_ALPHA, $WINANI_HIDE))
    Exit
EndFunc
Edited by Saunders

Share this post


Link to post
Share on other sites



Suggest you try embedding another graphically rich object and see if the issue is unique to IE or not.

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

Share this post


Link to post
Share on other sites

Hmm... any suggestions for "another graphically rich object"? Cus I barely know my way around the IE stuff, nevermind finding another one. Sorry. :)

Share this post


Link to post
Share on other sites

It did that to me, just let the animation effect start, sleep for maybe a second, then let it navigate to the page. It should work after that.

Share this post


Link to post
Share on other sites

Hmm... any suggestions for "another graphically rich object"? Cus I barely know my way around the IE stuff, nevermind finding another one. Sorry. :)

ptrex will get you started here with Adobe Acrobat Reader: #143407

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

Share this post


Link to post
Share on other sites

#6 ·  Posted (edited)

It did that to me, just let the animation effect start, sleep for maybe a second, then let it navigate to the page. It should work after that.

Unfortunately that defeats my entire purpose. I want the content visible as the window slides in. :\

ptrex will get you started here with Adobe Acrobat Reader: #143407

Dale

Thanks, I will look into this.

*Edit: Wow that thread is old, unfortunately his example isn't working properly, I'll have to fudge around with it. You wouldn't happen to know of anything else I could try in case I can't figure this out, would you? (Sorry to be such a nag :))

Edited by Saunders

Share this post


Link to post
Share on other sites

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

Share this post


Link to post
Share on other sites

_Animatewindow.au3 udf new download link please

Share this post


Link to post
Share on other sites

6 year old thread.

Nice work.

 

Zombie threads appear more often now - what a conincidence.


"Just be fred, all we gotta do, just be fred."  -Vocaliod

"That is a Hadouken. A KAMEHAMEHA would have taken him 13 days and 54 episodes to form." - Roden Hoxha

@tabhooked

Clock made of cursors ♣ Desktop Widgets ♣ Water Simulation

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0