Jump to content

GUI Image goes white while reloaded


Regency
 Share

Recommended Posts

So I wrote it and it "works" but the pages get whited out after i hit my "reload" button, see code,

#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include <IE.au3>
$oIE = ObjCreate("Shell.Explorer.2")
$oIE2 = ObjCreate("Shell.Explorer.2")
$T = GUICreate("TMN Status Bar", 870, 250, _
        (@DesktopWidth - 640) / 2, (@DesktopHeight - 580) / 2, $WS_OVERLAPPEDWINDOW + $WS_VISIBLE + $WS_CLIPSIBLINGS + $WS_EX_TOPMOST)
$GUIActiveX = GUICtrlCreateObj($oIE, 0, 0, 890, 50)
$GUIActiveX = GUICtrlCreateObj($oIE2, 40, 50, 800, 200)
$Reload = GUICtrlCreateButton("Reload", 0, 50, 40, 30, 0)
GUISetState(@SW_SHOWNOACTIVATE, $T) ;Show GUI
$oIE.navigate("tmnx.net/authenticated/userinfo.aspx")
$oIE2.navigate("tmnx.net/authenticated/rankbar.aspx")


While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit
        Case $Reload
            $oIE.navigate("tmnx.net/authenticated/userinfo.aspx")
            $oIE2.navigate("tmnx.net/authenticated/rankbar.aspx")
    EndSwitch

WEnd

GUIDelete()

First image where there is no white bar at top is how it looks normally when first open, then after i hit my "reload" button, the script makes the top and or the bottom white, its still there, i can highlight it, but its white.. anyone got any ides why and or a fix?

post-28129-12553907024421_thumb.png

post-28129-12553907168141_thumb.png

Link to comment
Share on other sites

Sometimes it stays white (unrefreshed) but when you drag some other small window (like calculator) over it

you will see it's only not painted window content. IE object also with all data is there.

I tried remove overlapping oIE and oIE2 and button but it didn't help

_IELoadWait($oIE) neither:

#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include <IE.au3>

$oIE = ObjCreate("Shell.Explorer.2")
$oIE2 = ObjCreate("Shell.Explorer.2")
$T = GUICreate("TMN Status Bar", 870, 250, _
        (@DesktopWidth - 640) / 2, (@DesktopHeight - 580) / 2, $WS_OVERLAPPEDWINDOW + $WS_VISIBLE + $WS_CLIPSIBLINGS + $WS_EX_TOPMOST)
$GUIActiveX = GUICtrlCreateObj($oIE, 10, 10, 800, 50)
$GUIActiveX = GUICtrlCreateObj($oIE2,50, 65, 800, 180)
$Reload = GUICtrlCreateButton("Reload", 0, 65, 40, 30, 0)
GUISetState(@SW_SHOWNOACTIVATE, $T) ;Show GUI
$oIE.navigate("tmnx.net/authenticated/userinfo.aspx")
$oIE2.navigate("tmnx.net/authenticated/rankbar.aspx")


While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit
        Case $Reload
            $oIE.navigate("tmnx.net/authenticated/userinfo.aspx")
;~          _IELoadWait($oIE)
            $oIE2.navigate("tmnx.net/authenticated/rankbar.aspx")
;~          _IELoadWait($oIE2)
    EndSwitch

WEnd

GUIDelete()

So for now it seems to me like Autoit's bug. Maybe there is some nifty workaround for that. Maybe Dale can help here (if no other).

Edited by Zedna
Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...