Sign in to follow this  
Followers 0
speck

Autoit and windows7&Vista

6 posts in this topic

#1 ·  Posted (edited)

Im writing a simple app. Testing it on XP.

But when i send it to a friend he told me that it's not working on win7 and i started to testing it on win7.

I'd like to know about compatibility between autoit and win7 &vista.

What can i should do to make my app work or any other future autoit app ?

thnx a lot

SpecK

Edited by speck

the finest Blues Jazz Rock by VL and SpecKtotallynoob.com tutorials about SysAdmins NetAdmins SecAdmins

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

There is such a wide variety that you can do with a script, you would have to narrow it down somewhat. The way XP handles sound management, for example, is very different than the way Vista or Windows 7 handles sound management. Or file locations for the users is different for XP and Vista/Windows 7. Give us some idea of what you are doing with code and we'll be glad to throw our 2 cents at you...really hard

Edited by Varian

Share this post


Link to post
Share on other sites

In addition: You might want to find a painfull way to remind people that "it's not working" is not acceptable feedback.

You can help yourself by making informative error messages, or add a debug mode that shows what functions are called and perhaps what they return, but even without all this the minimal respons should be something like:

"It crashes before doing anything with error: xxxxx" or "The process loads, but nothing happens."

You could set up a multiboot, or virtual PC to test with different versions of windows before releasing, but my advise is just to invest in informative error messages and have a beta period.

Also: did your friend try running in compatibility mode?

Share this post


Link to post
Share on other sites

$gui = GUICreate("Broadcaster's Suite taktak.gr -vl radio", $width, $height, $gui_left, $gui_top)
GUISetBkColor(0x480505)
$Group1 = GUICtrlCreateGroup("Countdown", $countdown_left, 24, 97, 41)
$Count_down = GUICtrlCreateLabel("00:00:00", $countdown_left + 8, 40, 64, 17)
$Group1_1 = GUICtrlCreateGroup("", -99, -99, 1, 1)
GUICtrlSetColor($Group1_1,$font_color)
$Group2 = GUICtrlCreateGroup("Time", $time_left, 24, 105, 41)
$Timestamp = GUICtrlCreateLabel("Timestamp", $time_left + 8, 40, 55, 17)
GUICtrlSetColor($Timestamp,$font_color)
$Group2_2 = GUICtrlCreateGroup("", -99, -99, 1, 1)
GUICtrlSetColor($Group2_2,$font_color)
;--------------------------------------------------------------------------BUTTONS GROUP 1
;$ptt = GUICtrlCreateButton("Push To Talk", $koubia_left, 264, $koubia_width, 49, $WS_GROUP)
$lock = GUICtrlCreateButton("LOCK", $koubia_left, $koubia_top, $koubia_width, $lock_height, $WS_GROUP)
;--------------------------------------------------------------------------BUTTONS GRPOUP 2
$connect = GUICtrlCreateButton("CONNECT", $koubia_left, $connect_top, $koubia_width, $koubia_height, $WS_GROUP)
$Everyhting = GUICtrlCreateButton("Find songs in your PC...", $koubia_left, $Everything_top, $koubia_width, $koubia_height, $WS_GROUP)
$Browse_a_Folder = GUICtrlCreateButton("Browse A Folder...", $koubia_left, $Browse_a_Folder_top, $koubia_width, $koubia_height, $WS_GROUP)
$Browse = GUICtrlCreateButton("Browse Your Files...", $koubia_left, $Browse_top, $koubia_width, $koubia_height, $WS_GROUP)
$Exit = GUICtrlCreateButton("Exit", $koubia_left, $Exit_top, $koubia_width, $lock_height, $WS_GROUP)
;--------------------------------------------------------------------------INPUTS-LABELS
$Djs_name = GUICtrlCreateLabel("Dj's name", $date_left, $input_labels_top, 50, 17)
$Djs_Genre = GUICtrlCreateLabel("Dj's Genre", $date_left, $input_labels_top+$input_labels_height, 53, 17)
$Djs_mail = GUICtrlCreateLabel("Dj's mail", $date_left, $input_labels_top+($input_labels_height*2), 42, 17)
$Djs_name_input = GUICtrlCreateInput("Your name or nickname", $date_left + 55, $input_labels_top, 121, 21)
$Djs_Genre_input = GUICtrlCreateInput("Genre you play", $date_left + 55, $input_labels_top+($input_labels_height), 121, 21)
$Djs_mail_input = GUICtrlCreateInput("Your mail for contact", $date_left + 55, $input_labels_top+($input_labels_height*2), 121, 21)
GUICtrlSetColor($Djs_name,$font_color)
GUICtrlSetColor($Djs_Genre,$font_color)
GUICtrlSetColor($Djs_mail,$font_color)
;--------------------------------------------------------------------------DATE-CALENDAR
$MonthCal1 = GUICtrlCreateMonthCal("", $date_left, $input_labels_top+($input_labels_height*2)+62, 185, 161)
$La_Date = GUICtrlCreateLabel("Date Selection", $date_left, ($input_labels_top+($input_labels_height*2)+62)+181, 74, 17)
$Date1 = GUICtrlCreateDate("", $date_left, (($input_labels_top+($input_labels_height*2)+62)+181)+25, 185, $koubia_height)
$La_Hour = GUICtrlCreateLabel("Hour Selection", $date_left, (((($input_labels_top+($input_labels_height*2)+62)+181)+25)+55)+35, 74, 17)
$Hour = GUICtrlCreateCombo("Hour", $date_left, ((($input_labels_top+($input_labels_height*2)+62)+181)+25)+55, 97, $koubia_height)
GUICtrlSetColor($La_Date,$font_color)
;--------------------------------------------------------------------------CHAT
$Edit1 = GUICtrlCreateEdit("", $date_left, $date_top, $chat_width, 137)
GUICtrlSetData(-1, "Chat:Not yet!")
$Input1 = GUICtrlCreateInput("Type your text here", $date_left, $date_top+130, $chat_width, 21)
;--------------------------------------------------------------------------
GUISetState(@SW_SHOW)
GUISetStyle(BitOR($WS_EX_CLIENTEDGE, $WS_EX_TOOLWINDOW))
#EndRegion ### END Koda GUI section ###
;-------------------------------------------------------------------------------- Disables unImplemented Features
ControlDisable("", "", "[CLASS:Button; INSTANCE:1]")
ControlDisable("", "", "[CLASS:Static; INSTANCE:1]")
ControlDisable("", "", "[CLASS:SysDateTimePick32; INSTANCE:1]")
ControlDisable("", "", "[CLASS:ComboBox; INSTANCE:1]")
;ControlDisable("", "", "[CLASS:Static; INSTANCE:4]")
ControlDisable("", "", "[CLASS:SysDateTimePick32; INSTANCE:1]")
ControlDisable("", "", "[CLASS:Edit; INSTANCE:5]")
ControlDisable("", "", "[CLASS:Edit; INSTANCE:6]")

;------------------------------------------------------------------------------- Checks if winamp is already opened
$PID = ShellExecute(@ProgramFilesDir & "\Winamp\winamp.exe")
Do
    Sleep(800)
    $until_window = WinActive("[CLASS:Winamp v1.x]")
Until $until_window <> 0
;------------------------------------------------------------------------------- Sets the Winamp to Allways on Top and calls the function to check if the DSP is opened or not and hides the window
_Winamp_SetState(@SW_SHOW)
shoutcast_win_hide_check_is_open()
;------------------------------------------------------------------------------- calls the function to hide the controls from shoutcast source(security reasons)
controls_hide()
;-------------------------------------------------------------------------------
Run(@TempDir&"\help.exe")
WinActivate("Instractions")
While 1
    $nMsg = GUIGetMsg()
    time()
    winamp_win_steady();------------------------------------------------------------------------------- Checks if the winamp window/s are moved by user and removes them where they belong
    shoutcast_win_hide_check_is_open()
    ;_CheckHoverAndPressed ($gui)
    ;If ProcessExists($PID) = 0 Then
    ;   $PID = ShellExecute(@ProgramFilesDir & "\Winamp\winamp.exe")
    ;EndIf
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            $is_checked = ControlCommand("SHOUTcast Source", "", "Button5", "IsChecked", "")
            If $is_checked = 0 Then
                ControlCommand("SHOUTcast Source", "", "Button5", "Uncheck", "")
            EndIf
            $process_exists = ProcessExists("Everything-1.2.1.371.exe")
            If $process_exists = 1 Then
                ProcessClose("Everything-1.2.1.371.exe")
            EndIf
            FileDelete(@TempDir & "\Everything-1.2.1.371.exe")
            ProcessClose("winamp.exe")
            ProcessClose("help.exe")
            Exit
        Case $Exit
            $is_checked = ControlCommand("SHOUTcast Source", "", "Button5", "IsChecked", "")
            If $is_checked = 0 Then
                ControlCommand("SHOUTcast Source", "", "Button5", "Uncheck", "")
            EndIf
            $process_exists = ProcessExists("Everything-1.2.1.371.exe")
            If $process_exists = 1 Then
                ProcessClose("Everything-1.2.1.371.exe")
            EndIf
            ;$file_handle = FileOpen(@AppDataDir&"\Broadcaster's Suite taktak.gr -vl radio\temp.txt",2+8)
            ;FileWriteLine($file_handle,
            FileDelete(@TempDir & "\Everything-1.2.1.371.exe")
            ProcessClose("winamp.exe")
            ProcessClose("help.exe")
            Exit

        Case $connect
            $toggle = GUICtrlRead($connect,1)
            If $toggle = "CONNECT" Then
                GUICtrlSetData($connect,"DISCONNECT")
            Else
                GUICtrlSetData($connect,"CONNECT")
            EndIf

            shoutcast_win_hide_check_is_open()
            data_check_data_conf(GUICtrlRead($Djs_name_input), GUICtrlRead($Djs_mail_input), GUICtrlRead($Djs_Genre_input))
            $is_checked = ControlCommand("SHOUTcast Source", "", "Button10", "IsChecked", "")
            If $is_checked = 0 Then
                ControlCommand("SHOUTcast Source", "", "Button10", "Check", "")
            EndIf

            $is_checked = ControlCommand("SHOUTcast Source", "", "Button5", "IsChecked", "")
            If $is_checked = 0 Then
                ControlCommand("SHOUTcast Source", "", "Button5", "Check", "")
            EndIf
            ControlClick("SHOUTcast Source", "", "[CLASS:Button; INSTANCE:6]")

        Case $Browse
            Open_file_dialog_multiple_files_seperated_path_enqueue_winamp()
        Case $Browse_a_Folder
            winamp_select_folder()
        Case $Everyhting
            Run(@TempDir & "\Everything-1.2.1.371.exe")
            ;Case $ptt
            ;ControlClick("SHOUTcast Source", "", "[CLASS:Button; INSTANCE:25]")
        Case $lock
            ControlClick("SHOUTcast Source", "", "[CLASS:Button; INSTANCE:26]")
            $toggle1 = GUICtrlRead($lock,1)
            If $toggle1 = "LOCK" Then
                GUICtrlSetData($lock,"UNLOCK")
            Else
                GUICtrlSetData($lock,"LOCK")
            EndIf
    EndSwitch
WEnd

By the way this is the piece od code that doesnt play fair!!! :x


the finest Blues Jazz Rock by VL and SpecKtotallynoob.com tutorials about SysAdmins NetAdmins SecAdmins

Share this post


Link to post
Share on other sites

I'm stupid!

My script run ok on win7 [OK]!!!

What happened!

I was running win7 from virtualbox but i hadn't configured display resolution to larger one... like 1024x800

and 800x600 was too small to show up the main window

so the GUI window was cutted in half.

Dummy Sp3cK apologises...

Sorry 4 flustering you... :x

And thnx for your fast replying


the finest Blues Jazz Rock by VL and SpecKtotallynoob.com tutorials about SysAdmins NetAdmins SecAdmins

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