Jump to content
Sign in to follow this  

Deleting disabled img ctrl hard crashes AutoIt

Hard Crash?  

2 members have voted

  1. 1. Does the example script cause a AutoIt hard crash in Vista for you?

    • Yes (under Vista)
    • No (under Vista)

Recommended Posts



The summary and the following code should be enough to understand the problem. Please take any image file say "example.jpg" and put it in the same directory as the script - if the file does not exist, the crash won't occur - and your result in such a case will be without much purpose.

Global Const $GUI_DISABLE = 128
Local $msg
Local $tp = @TempDir
Local $ginstall = GUICreate("installer",420,375)

Local $b_yes = GUICtrlCreateButton ("Yes",235,335,80,26)
FileInstall("example.jpg",$tp &"\top",1)
Local $i_img = GUICtrlCreatePic ($tp &"\top",0,52,420,270)
GuiCtrlSetState(-1,$GUI_DISABLE) ;$i_img IS NOW DISABLED
While 1
    $msg = GUIGetMsg ()
    Switch $msg
        Case $b_yes
            GUICtrlDelete($i_img) ;CRASH AT THIS POINT


If you are a Vista user, run the above code with an example.jpg file and then press Yes. Please tell me if AutoIt crashes or not - the preferred AutoIt version for testing is

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  


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.