Weiss nicht weiter!
Habe versucht aus meinem Script und dem Script "tristatestuff" eine kombienation zu machen.
Kann mir Bitte einer helfen!
Windows und Software-Menü
-
- [ offen ]
-
Johnny1980 -
12. Mai 2007 um 16:20 -
Geschlossen -
Erledigt
-
-
- Offizieller Beitrag
Hi!
Quelltext bitte mit einem Spoiler- und AutoIt-Tag einbinden.
Außerdem bitte Fehlerbeschreibung dazu...Je leichter es uns gemacht wird, zu helfen, desto eher passiert das.
Danke,
peethbee -
Hier der ganze Quelltext.
Spoiler anzeigen
; Events and messages
Global Const $GUI_EVENT_CLOSE = -3
Global Const $GUI_EVENT_MINIMIZE = -4
Global Const $GUI_EVENT_RESTORE = -5
Global Const $GUI_EVENT_MAXIMIZE = -6
Global Const $GUI_SHOW = 16
Global Const $GUI_HIDE = 32
Global Const $GUI_ENABLE = 64
Global Const $GUI_DISABLE = 128
Global Const $GUI_UNCHECKED = 4
Global Const $GUI_CHECKED = 1
; Window Styles
Global Const $WS_TILED = 0
Global Const $WS_OVERLAPPED = 0
Global Const $WS_MAXIMIZEBOX = 0x00010000
Global Const $WS_MINIMIZEBOX = 0x00020000
Global Const $WS_TABSTOP = 0x00010000
Global Const $WS_GROUP = 0x00020000
Global Const $WS_SIZEBOX = 0x00040000
Global Const $WS_THICKFRAME = 0x00040000
Global Const $WS_SYSMENU = 0x00080000
Global Const $WS_BORDER = 0x00800000
Global Const $WS_CAPTION = 0x00C00000
Global Const $WS_OVERLAPPEDWINDOW = 0x00CF0000
Global Const $WS_TILEDWINDOW = 0x00CF0000
Global Const $WS_MAXIMIZE = 0x01000000
Global Const $WS_CLIPCHILDREN = 0x02000000
Global Const $WS_CLIPSIBLINGS = 0x04000000
Global Const $WS_DISABLED = 0x08000000
Global Const $WS_VISIBLE = 0x10000000
Global Const $WS_MINIMIZE = 0x20000000
Global Const $WS_CHILD = 0x40000000
Global Const $WS_POPUP = 0x80000000
Global Const $WS_POPUPWINDOW = 0x80880000
Global Const $DS_MODALFRAME = 0x80
Global Const $DS_SETFOREGROUND = 0x00000200
Global Const $DS_CONTEXTHELP = 0x00002000
; Window Extended Styles
Global Const $WS_EX_ACCEPTFILES = 0x00000010
Global Const $WS_EX_MDICHILD = 0x00000040
Global Const $WS_EX_APPWINDOW = 0x00040000
Global Const $WS_EX_CLIENTEDGE = 0x00000200
Global Const $WS_EX_CONTEXTHELP = 0x00000400
Global Const $WS_EX_DLGMODALFRAME = 0x00000001
Global Const $WS_EX_LEFTSCROLLBAR = 0x00004000
Global Const $WS_EX_OVERLAPPEDWINDOW = 0x00000300
Global Const $WS_EX_RIGHT = 0x00001000
Global Const $WS_EX_STATICEDGE = 0x00020000
Global Const $WS_EX_TOPMOST = 0x00000008
Global Const $WS_EX_TRANSPARENT = 0x00000020
Global Const $WS_EX_WINDOWEDGE = 0x00000100
Global Const $WS_EX_LAYERED = 0x00080000
Global Const $LVS_EX_FULLROWSELECT = 0x00000020
; Label/Pic/Icon
Global Const $SS_CENTER = 1
Global Const $SS_RIGHT = 2
Global Const $SS_ICON = 3
Global Const $SS_BLACKRECT = 4
Global Const $SS_GRAYRECT = 5
Global Const $SS_WHITERECT = 6
Global Const $SS_BLACKFRAME = 7
Global Const $SS_GRAYFRAME = 8
Global Const $SS_WHITEFRAME = 9
Global Const $SS_SIMPLE = 11
Global Const $SS_LEFTNOWORDWRAP = 12
Global Const $SS_BITMAP = 15
Global Const $SS_ETCHEDHORZ = 16
Global Const $SS_ETCHEDVERT = 17
Global Const $SS_ETCHEDFRAME = 18
Global Const $SS_NOPREFIX = 0x0080
Global Const $SS_NOTIFY = 0x0100
Global Const $SS_CENTERIMAGE = 0x0200
Global Const $SS_RIGHTJUST = 0x0400
Global Const $SS_SUNKEN = 0x1000
; Button
Global Const $BS_BOTTOM = 0x0800
Global Const $BS_CENTER = 0x0300
Global Const $BS_DEFPUSHBUTTON = 0x0001
Global Const $BS_LEFT = 0x0100
Global Const $BS_MULTILINE = 0x2000
Global Const $BS_PUSHBOX = 0x000A
Global Const $BS_PUSHLIKE = 0x1000
Global Const $BS_RIGHT = 0x0200
Global Const $BS_RIGHTBUTTON = 0x0020
Global Const $BS_TOP = 0x0400
Global Const $BS_VCENTER = 0x0C00
Global Const $BS_FLAT = 0x8000
Global Const $BS_ICON = 0x0040
Global Const $BS_BITMAP = 0x0080
; TreeView
Global Const $TVS_HASBUTTONS = 0x0001
Global Const $TVS_HASLINES = 0x0002
Global Const $TVS_LINESATROOT = 0x0004
Global Const $TVS_DISABLEDRAGDROP = 0x0010
Global Const $TVS_SHOWSELALWAYS = 0x0020
Global Const $TVS_NOTOOLTIPS = 0x0080
Global Const $TVS_CHECKBOXES = 0x0100
Global Const $TVS_TRACKSELECT = 0x0200
Global Const $TVS_SINGLEEXPAND = 0x0400
Global Const $TVS_FULLROWSELECT = 0x1000
Global Const $TVS_NOSCROLL = 0x2000
Global Const $TVS_NONEVENHEIGHT = 0x4000
; Graphic
Global Const $GUI_GR_CLOSE = 1
Global Const $GUI_GR_LINE = 2
Global Const $GUI_GR_BEZIER = 4
Global Const $GUI_GR_MOVE = 6
Global Const $GUI_GR_COLOR = 8
Global Const $GUI_GR_RECT = 10
Global Const $GUI_GR_ELLIPSE = 12
Global Const $GUI_GR_PIE = 14
Global Const $GUI_GR_DOT = 16
Global Const $GUI_GR_PIXEL = 18
Global Const $GUI_GR_HINT = 20
Global Const $GUI_GR_REFRESH = 22
Global Const $GUI_GR_PENSIZE = 24Global Const $GUI_SS_DEFAULT_GUI = BitOR($WS_MINIMIZEBOX, $WS_CAPTION, $WS_POPUP, $WS_SYSMENU)
;-----------------------------------------------------------------------------
Dim $main_GUI
Dim $Exit_button
Dim $Back_button
Dim $Info_button
Dim $i386
Dim $tools
Dim $oem_apps
Dim $oem_ms_apps
Dim $oem_treiber
Dim $software
Dim $serial
Dim $docs
Dim $sys32
Dim $office
Dim $gui_width
Dim $gui_height
Dim $gui_child_height
Dim $treeviewGlobal $Drive, $DriveTyp, $Uninstall_Path
;-----------------------------------------------------------------------------
;############################################################################
; Fenster - Grösse:
;------------------
$gui_width = 800
$gui_height = 600
$gui_child_height = $gui_height - 42; Startsound:
;------------
SoundPlay(@ScriptDir & "\Setup\Button_Sound\winSpaceSysStart.wav"); Definieren des TrayIcons:
;--------------------------
TraySetIcon(@ScriptDir & "\Setup\Pics\install.ico"); Funktioniert nur ab Version 3.1.1.5 !!!!;#############################################################################
;*******************************************************************************************
; Definieren der GUI-Fenster:
; ===========================;*******************************************************************************************
; Main-Window mit Exit-, Back-,Passwort-,Info- und Version-Button:
;--------------------------------------------------------
$main_GUI = GUICreate("",$gui_width,$gui_height,-1,-1,BitOr($GUI_SS_DEFAULT_GUI,$WS_CLIPSIBLINGS))
GUISetBkColor(0xBAB7B7)
$Exit_button = GUICtrlCreateButton("Exit",$gui_width - 90,$gui_height - 36,70,30)
GUICtrlSetTip(-1,"Programm beenden?")
GUICtrlSetCursor(-1, 0)
$Back_button = GUICtrlCreateButton("Zurück",$gui_width - 170,$gui_height - 36,70,30)
GUICtrlSetTip(-1,"Zum Hauptauswahl-Fenster zurückkehren?")
GUICtrlSetCursor(-1, 0)
$Info_button = GUICtrlCreateButton(Chr(169),$gui_width - 790,$gui_height - 30,15,15)
GUICtrlSetTip(-1,"Info")
GUICtrlSetCursor(-1, 4)
$Serial_button = GUICtrlCreateButton(Chr(174),$gui_width - 770,$gui_height - 30,15,15)
GUICtrlSetTip(-1,"Aktuelle Windows Seriennummer auslesen?")
GUICtrlSetCursor(-1, 4)
$Haupt_Drive_button = GUICtrlCreateButton(Chr(164),$gui_width - 750,$gui_height - 30,15,15)
GUICtrlSetTip(-1,"Festplatten und aktuellen Speicherplatz anzeigen?")
GUICtrlSetCursor(-1, 4)
$Passwort_button = GUICtrlCreateButton("Passwort",$gui_width - 250,$gui_height - 36,70,30)
GUICtrlSetTip(-1,"Passwort?")
GUICtrlSetCursor(-1, 0)
GUISetState();##########################################################################################
; Hauptfenster für die Auswahl von Windows, Office u. Programme:
;---------------------------------------------------------------
Global $Haupt_GUI = GUICreate("",$gui_width,$gui_child_height,0,0,$WS_CHILD,-1,$main_GUI)
$Pic_Haupt = GUICtrlCreatePic(@ScriptDir & "\Setup\Pics\main.jpg",-1,-1, 800, 600, $WS_EX_TRANSPARENT)
DllCall ( "user32.dll", "int", "AnimateWindow", "hwnd", $Haupt_GUI, "int", 1000, "long", 0x00040010 );explode
Sleep(1000)
GUICtrlSetColor(-1,0x000000)
GUICtrlSetFont(-1,14,600); Esrtellen der Buttons für das Hauptfenster:
;--------------------------------------------
Global $Haupt_Win_button = GUICtrlCreateButton("",($gui_width - 755) / 2,$gui_child_height - 394,33,33, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\button1.bmp")
GUICtrlSetTip(-1,"Zum Windows Installations-Fenster wechseln?")
GUICtrlSetCursor(-1, 0)
Global $Haupt_Office_button = GUICtrlCreateButton("",($gui_width - 755) / 2,$gui_child_height - 286,33,33, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\button1.bmp")
GUICtrlSetTip(-1,"Zum Office Installations-Fenster wechseln?")
GUICtrlSetCursor(-1, 0)
Global $Haupt_Progs_button = GUICtrlCreateButton("",($gui_width - 755) / 2,$gui_child_height - 178,33,33, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\button1.bmp")
GUICtrlSetTip(-1,"Zum Programm Installations-Fenster wechseln?")
GUICtrlSetCursor(-1, 0)
GUICtrlSetState ($Back_button, $GUI_DISABLE)
GUISetState();############################################################################################
; Windows - Installationsfenster:
;------------------------------
Global $Win_GUI = GUICreate("",$gui_width,$gui_child_height,0,0,$WS_CHILD,-1,$main_GUI)
$Pic_Win = GUICtrlCreatePic(@ScriptDir & "\Setup\Pics\windows.jpg",-1,-1, 800, 600, $WS_EX_TRANSPARENT )
GUICtrlSetColor(-1,0x000000)
GUICtrlSetFont(-1,14,600); Erstellen der Buttons:
;-----------------------
Global $Win_button1 = GUICtrlCreateButton(">>",($gui_width - 735) / 2,$gui_child_height - 355,35,20)
GUICtrlSetCursor(-1, 0)
Global $Win_button2 = GUICtrlCreateButton(">>",($gui_width - 735) / 2,$gui_child_height - 315,35,20)
GUICtrlSetCursor(-1, 0)
Global $Win_button3 = GUICtrlCreateButton(">>",($gui_width - 735) / 2,$gui_child_height - 275,35,20)
GUICtrlSetCursor(-1, 0)
Global $Win_button4 = GUICtrlCreateButton(">>",($gui_width - 735) / 2,$gui_child_height - 235,35,20)
GUICtrlSetCursor(-1, 0)
Global $Win_button5 = GUICtrlCreateButton(">>",($gui_width - 735) / 2,$gui_child_height - 195,35,20)
GUICtrlSetCursor(-1, 0)
Global $Win_button6 = GUICtrlCreateButton(">>",($gui_width - 735) / 2,$gui_child_height - 155,35,20)
GUICtrlSetCursor(-1, 0)
Global $Win_button7 = GUICtrlCreateButton(">>",($gui_width - 735) / 2,$gui_child_height - 115,35,20)
GUICtrlSetCursor(-1, 0)
Global $Win_button8 = GUICtrlCreateButton(">>",($gui_width - 735) / 2,$gui_child_height - 75,35,20)
GUICtrlSetCursor(-1, 0);#############################################################################################
; Office - Installationsfenster:
;-------------------------------
Global $Office_GUI = GUICreate("",$gui_width,$gui_child_height,0,0,$WS_CHILD,-1,$main_GUI)
$Pic_Office = GUICtrlCreatePic(@ScriptDir & "\Setup\Pics\office.jpg",-1,-1, 800, 600, $WS_EX_TRANSPARENT )
GUICtrlSetFont(-1,14,600);Erstellen der Labels:
;---------------------
Global $Office_Label1 = GUICtrlCreateLabel("Office 2007",($gui_width - 430) / 2,$gui_child_height - 330,200,30)
GUICtrlSetBkColor(-1,0xFFFFFF)
GUICtrlSetFont (-1,20, 400, 2)
Global $Office_Label2 = GUICtrlCreateLabel("Open Office",($gui_width - 430) / 2,$gui_child_height - 230,200,30)
GUICtrlSetBkColor(-1,0xFFFFFF)
GUICtrlSetFont (-1,20, 400, 2); Erstellen der Buttons:
;-----------------------
Global $Office_button1 = GUICtrlCreateButton("",($gui_width - 600) / 2,$gui_child_height - 345,70,70, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\Office 2007.bmp")
GUICtrlSetCursor(-1, 0)
Global $Office_button2 = GUICtrlCreateButton("",($gui_width - 600) / 2,$gui_child_height - 245,70,70, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\OpenOffice.bmp")
GUICtrlSetCursor(-1, 0);###################################################################################################
; Software - Installationsfenster:
;---------------------------------
Global $Progs_GUI = GUICreate("",$gui_width,$gui_child_height,0,0,$WS_CHILD,-1,$main_GUI)
$Pic_Progs = GUICtrlCreatePic(@ScriptDir & "\Setup\Pics\software.jpg",-1,-1, 800, 600, $WS_EX_TRANSPARENT )
GUICtrlSetFont(-1,14,600); Erstellen der Buttons:
;-----------------------
#cs
Global $Progs_button4 = GUICtrlCreateButton("Alles auswählen",($gui_width -600) / 2,$gui_child_height - 38,90,30)
GUICtrlSetTip(-1,"Alle Programme auwählen?")
GUICtrlSetCursor(-1, 0)
Global $Progs_button5 = GUICtrlCreateButton("Auswahl löschen",($gui_width -400) / 2,$gui_child_height - 38,90,30)
GUICtrlSetTip(-1,"Alle gewählten Programme wieder entfernen?")
GUICtrlSetCursor(-1, 0)
#ce
Global $Progs_button6 = GUICtrlCreateButton("Installieren",($gui_width -200) / 2,$gui_child_height - 38,90,30)
GUICtrlSetTip(-1,"Die ausgewählten Programme installieren?")
GUICtrlSetCursor(-1, 0)$expand = 0
$text1 = "Ausklappen"
$text2 = "Einklappen"
Global $Btn_expand = GUICtrlCreateButton($text1,($gui_width -600) / 2,$gui_child_height - 38,90,30)
GUICtrlSetTip(-1,"Ausklappen und Einklappen?")
GUICtrlSetCursor(-1, 0)
GUICtrlSetOnEvent(-1, "_expand")$switch = 0
$text3 = "Alle wählen"
$text4 = "Wahl aufheben"
Global $Btn_all = GUICtrlCreateButton($text3,($gui_width -400) / 2,$gui_child_height - 38,90,30)
GUICtrlSetTip(-1,"Alle wählen und Wahl aufheben?")
GUICtrlSetCursor(-1, 0)
GUICtrlSetOnEvent(-1, "_all");Erstellen des TreeView:
;-----------------------
Global $nTV = GUICtrlCreateTreeView (($gui_width -600) / 2,$gui_child_height - 370,300,215,BitOr($TVS_HASBUTTONS,$TVS_HASLINES,$TVS_LINESATROOT,$TVS_DISABLEDRAGDROP,$TVS_SHOWSELALWAYS,$TVS_CHECKBOXES),$WS_EX_TRANSPARENT )
GUICtrlSetBkColor(-1,0xFFFFFF)
GUICtrlSetFont (-1,10, 400, 2)
GUICtrlSetCursor(-1, 0)
;Erstellen der TreeView-Labels und Icons:
;----------------------------------------
$nItem1 = GUICtrlCreateTreeViewItem("Messenger", $nTV)
GUICtrlSetColor(-1, 0xFF0000)
GUICtrlSetImage(-1, "explorer.exe", 0)
$nItem2 = GUICtrlCreateTreeViewItem("Internet", $nTV)
GUICtrlSetColor(-1, 0xFF00FF)
$nItem3 = GUICtrlCreateTreeViewItem("Tools", $nTV)
GUICtrlSetColor(-1, 0xFF8C00)
$nItem4 = GUICtrlCreateTreeViewItem("Mediaplayer", $nTV)
GUICtrlSetColor(-1, 0x00BFFF)
$nSubItem1 = GUICtrlCreateTreeViewItem("InterCafe Client", $nItem1)
GUICtrlSetImage(-1, "regedit.exe", 0)
$nSubItem2 = GUICtrlCreateTreeViewItem("ICQ 5.1", $nItem1)
GUICtrlSetImage(-1, "regedit.exe", 0)
$nSubItem3 = GUICtrlCreateTreeViewItem("Opera", $nItem2)
GUICtrlSetImage(-1, "regedit.exe", 0)
$nSubItem4 = GUICtrlCreateTreeViewItem("Mozilla Firefox 2", $nItem2)
GUICtrlSetImage(-1, "regedit.exe", 0)
$nSubItem5 = GUICtrlCreateTreeViewItem("Adobe Reader", $nItem3)
GUICtrlSetImage(-1, "regedit.exe", 0)
$nSubItem6 = GUICtrlCreateTreeViewItem("WinRar", $nItem3)
GUICtrlSetImage(-1, "regedit.exe", 0)
$nSubItem7 = GUICtrlCreateTreeViewItem("VLC Player", $nItem4)
GUICtrlSetImage(-1, "regedit.exe", 0)
$nSubItem8 = GUICtrlCreateTreeViewItem("QuickTime Player", $nItem4)
GUICtrlSetImage(-1, "regedit.exe", 0)
$nSubItem9 = GUICtrlCreateTreeViewItem("Media Player 11", $nItem4)
GUICtrlSetImage(-1, "regedit.exe", 0)Func _expand()
If $expand = 0 Then
;_GUICtrlTreeViewExpand($nTV)
$expand = 1
GUICtrlSetData($Btn_expand, $text2)
Else
;_GUICtrlTreeViewExpand($nTV, 0)
$expand = 0
GUICtrlSetData($Btn_expand, $text1)
EndIf
EndFuncFunc _all()
If $switch = 0 Then
;SelectFull()
$switch = 1
GUICtrlSetData($Btn_all, $text4)
Else
;ReSelect()
$switch = 0
GUICtrlSetData($Btn_all, $text3)
EndIf
EndFunc;####################################################################################################
; Passwort - Installationsfenster:
;---------------------------------
Global $Passwort_GUI = GUICreate("",$gui_width,$gui_child_height,0,0,$WS_CHILD,-1,$main_GUI)
$Pic_Haupt = GUICtrlCreatePic(@ScriptDir & "\Setup\Pics\uninstall.jpg",-1,-1, 800, 600)
GuiCtrlSetState(-1, $GUI_DISABLE)
GUICtrlSetFont(-1,14,600);Erstellen der Label:
;----------------------------
Global $Passwort_Label1 = GUICtrlCreateLabel ("AutoIt",($gui_width -680) / 2,$gui_child_height - 392 , 350, 20)
GUICtrlSetBkColor(-1,0xd4d4d4)
Global $Passwort_Label2 = GUICtrlCreateLabel ("AutoPlay 6",($gui_width -680) / 2,$gui_child_height - 342 , 350, 20)
GUICtrlSetBkColor(-1,0xd4d4d4)
Global $Passwort_Label3 = GUICtrlCreateLabel ("Reg Rapper",($gui_width -680) / 2,$gui_child_height - 292 , 350, 20)
GUICtrlSetBkColor(-1,0xd4d4d4)
Global $Passwort_Label4 = GUICtrlCreateLabel ("Reg Shot",($gui_width -680) / 2,$gui_child_height - 242 , 350, 20)
GUICtrlSetBkColor(-1,0xd4d4d4)
Global $Passwort_Label5 = GUICtrlCreateLabel ("ResHacker",($gui_width -680) / 2,$gui_child_height - 192 , 350, 20)
GUICtrlSetBkColor(-1,0xd4d4d4)
Global $Passwort_Label6 = GUICtrlCreateLabel ("CMenü",($gui_width -680) / 2,$gui_child_height - 142 , 350, 20)
GUICtrlSetBkColor(-1,0xd4d4d4); Erstellen der Buttons:
;-----------------------
Global $passwort_button1 = GUICtrlCreateButton("",($gui_width - 750) / 2,$gui_child_height - 400,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\autoit.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button2 = GUICtrlCreateButton("",($gui_width - 750) / 2,$gui_child_height - 350,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\autoplay6.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button3 = GUICtrlCreateButton("",($gui_width - 750) / 2,$gui_child_height - 300,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\regrap.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button4 = GUICtrlCreateButton("",($gui_width - 750) / 2,$gui_child_height - 250,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\regshot.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button5 = GUICtrlCreateButton("",($gui_width - 750) / 2,$gui_child_height - 200,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\reshacker.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button6 = GUICtrlCreateButton("",($gui_width - 750) / 2,$gui_child_height - 150,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\cmenü.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button7 = GUICtrlCreateButton("",($gui_width - 750) / 2,$gui_child_height - 100,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\TuneUp 2007.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button8 = GUICtrlCreateButton("",($gui_width - 200) / 2,$gui_child_height - 400,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\TuneUp 2007.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button9 = GUICtrlCreateButton("",($gui_width - 200) / 2,$gui_child_height - 350,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\TuneUp 2007.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button10 = GUICtrlCreateButton("",($gui_width - 200) / 2,$gui_child_height - 300,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\TuneUp 2007.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button11 = GUICtrlCreateButton("",($gui_width - 200) / 2,$gui_child_height - 250,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\TuneUp 2007.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button12 = GUICtrlCreateButton("",($gui_width - 200) / 2,$gui_child_height - 200,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\TuneUp 2007.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button13 = GUICtrlCreateButton("",($gui_width - 200) / 2,$gui_child_height - 150,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\TuneUp 2007.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button14 = GUICtrlCreateButton("",($gui_width - 200) / 2,$gui_child_height - 100,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\TuneUp 2007.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button15 = GUICtrlCreateButton("",($gui_width - -350) / 2,$gui_child_height - 400,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\TuneUp 2007.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button16 = GUICtrlCreateButton("",($gui_width - -350) / 2,$gui_child_height - 350,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\TuneUp 2007.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button17 = GUICtrlCreateButton("",($gui_width - -350) / 2,$gui_child_height - 300,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\TuneUp 2007.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button18 = GUICtrlCreateButton("",($gui_width - -350) / 2,$gui_child_height - 250,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\TuneUp 2007.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button19 = GUICtrlCreateButton("",($gui_width - -350) / 2,$gui_child_height - 200,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\TuneUp 2007.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button20 = GUICtrlCreateButton("",($gui_width - -350) / 2,$gui_child_height - 150,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\TuneUp 2007.bmp")
GUICtrlSetCursor(-1, 0)
Global $passwort_button21 = GUICtrlCreateButton("",($gui_width - -350) / 2,$gui_child_height - 100,30,30, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\TuneUp 2007.bmp")
GUICtrlSetCursor(-1, 0);###################################################################################################
; Drive Kapazität-Fenster:
;-------------------------Global $Drive_GUI = GUICreate("",$gui_width,$gui_child_height,0,0,$WS_CHILD,-1,$main_GUI)
$Pic_Haupt = GUICtrlCreatePic(@ScriptDir & "\Setup\Pics\drive.jpg",-1,-1, 800, 600, $WS_EX_TRANSPARENT )
GUICtrlSetFont(-1,14,600); Erstellen der Labels:
;----------------------
Global $Drive_Label = GuiCtrlCreateLabel("", 200, $gui_child_height - 400, 400, 25, $SS_CENTER )
GUICtrlSetBkColor(-1,0xd4d4d4)
GUICtrlSetFont (-1,14, 400, 2)
GuiCtrlCreateLabel("Drive:", 25, $gui_child_height - 355, 40, 20)
GUICtrlSetBkColor(-1,0xd4d4d4)
GUICtrlSetFont (-1,10, 400, 2)
GuiCtrlCreateLabel("Bezeichnung:", 70, $gui_child_height - 355, 100, 20)
GUICtrlSetBkColor(-1,0xd4d4d4)
GUICtrlSetFont (-1,10, 400, 2)
GuiCtrlCreateLabel("Ansicht:", 175, $gui_child_height - 355, 200, 20)
GUICtrlSetBkColor(-1,0xd4d4d4)
GUICtrlSetFont (-1,10, 400, 2)
GuiCtrlCreateLabel("File Sys: ", 380, $gui_child_height - 355, 70, 20)
GUICtrlSetBkColor(-1,0xd4d4d4)
GUICtrlSetFont (-1,10, 400, 2)
GuiCtrlCreateLabel("Gesammt:(GB) ", 455, $gui_child_height - 355, 85, 20)
GUICtrlSetBkColor(-1,0xd4d4d4)
GUICtrlSetFont (-1,10, 400, 2)
GuiCtrlCreateLabel("Besetzt:(GB) ", 545, $gui_child_height - 355, 80, 20)
GUICtrlSetBkColor(-1,0xd4d4d4)
GUICtrlSetFont (-1,10, 400, 2)
GuiCtrlCreateLabel("Frei:(GB) ", 630, $gui_child_height - 355, 80, 20)
GUICtrlSetBkColor(-1,0xd4d4d4)
GUICtrlSetFont (-1,10, 400, 2)
GuiCtrlCreateLabel("Status:", 715, $gui_child_height - 355, 70, 20)
GUICtrlSetBkColor(-1,0xd4d4d4)
GUICtrlSetFont (-1,10, 400, 2);Erstellen des Rasters:
;----------------------
GUICtrlCreateLine(25, $gui_child_height - 333, 782, $gui_child_height - 333, 5, "0x000000")
GUICtrlCreateLine(66, $gui_child_height - 355, 66, $gui_child_height - 331, 3, "0x000000")
GUICtrlCreateLine(171, $gui_child_height - 355, 171, $gui_child_height - 331, 3, "0x000000")
GUICtrlCreateLine(376, $gui_child_height - 355, 376, $gui_child_height - 331, 3, "0x000000")
GUICtrlCreateLine(451, $gui_child_height - 355, 451, $gui_child_height - 331, 3, "0x000000")
GUICtrlCreateLine(541, $gui_child_height - 355, 541, $gui_child_height - 331, 3, "0x000000")
GUICtrlCreateLine(626, $gui_child_height - 355, 626, $gui_child_height - 331, 3, "0x000000")
GUICtrlCreateLine(711, $gui_child_height - 355, 711, $gui_child_height - 331, 3, "0x000000"); Erstellen der Buttons:
;-----------------------
Global $Drive_button1 = GUICtrlCreateButton("", 25,$gui_child_height - 48,36,36, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\dfrg.bmp")
GUICtrlSetTip(-1,"Datenträger defragmentieren?")
GUICtrlSetCursor(-1, 0)
Global $Drive_button2 = GUICtrlCreateButton("", 71,$gui_child_height - 48,36,36, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\cleanmgr.bmp")
GUICtrlSetTip(-1,"Datenträger bereinigen?")
GUICtrlSetCursor(-1, 0)
Global $Drive_button3 = GUICtrlCreateButton("", 117,$gui_child_height - 48,36,36, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\ntbackup.bmp")
GUICtrlSetTip(-1,"BackUp erstellen?")
GUICtrlSetCursor(-1, 0)
Global $Drive_button4 = GUICtrlCreateButton("", 163,$gui_child_height - 48,36,36, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\diskmgmt.bmp")
GUICtrlSetTip(-1,"Diskmanagement starten?")
GUICtrlSetCursor(-1, 0)
Global $Drive_button5 = GUICtrlCreateButton("", 209,$gui_child_height - 48,36,36, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\restore.bmp")
GUICtrlSetTip(-1,"Systemwiederherstellung starten?")
GUICtrlSetCursor(-1, 0)
$Key1 = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SystemRestore", "DisableSR")
$Key2 = RegRead("HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\srservice", "Start")
If $Key1 == "1" And $Key2 == "4" then
GUICtrlSetState (-1, $GUI_DISABLE)
Else
GUICtrlSetState (-1, $GUI_ENABLE)
EndIf
Global $Drive_button6 = GUICtrlCreateButton("", 255,$gui_child_height - 48,36,36, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\compmgmt.bmp")
GUICtrlSetTip(-1,"Computerverwaltung starten?")
GUICtrlSetCursor(-1, 0)
Global $Drive_button7 = GUICtrlCreateButton("", 301,$gui_child_height - 48,36,36, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\devmgmt.bmp")
GUICtrlSetTip(-1,"Gerätemanager starten?")
GUICtrlSetCursor(-1, 0)
Global $Drive_button8 = GUICtrlCreateButton("", 347,$gui_child_height - 48,36,36, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\dxdiag.bmp")
GUICtrlSetTip(-1,"DircetX Diagnoseprogramm starten?")
GUICtrlSetCursor(-1, 0)
Global $Drive_button9 = GUICtrlCreateButton("", 393,$gui_child_height - 48,36,36, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\regedt32.bmp")
GUICtrlSetTip(-1,"Registrierungs-Editor starten?")
GUICtrlSetCursor(-1, 0)
Global $Drive_button10 = GUICtrlCreateButton("", 439,$gui_child_height - 48,36,36, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\explorer.bmp")
GUICtrlSetTip(-1,"Windows Explorer starten?")
GUICtrlSetCursor(-1, 0)
Global $Drive_button11 = GUICtrlCreateButton("", 485,$gui_child_height - 48,36,36, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\cmd.bmp")
GUICtrlSetTip(-1,"Eingabeaufforderung starten?")
GUICtrlSetCursor(-1, 0)
Global $Drive_button12 = GUICtrlCreateButton("", 531,$gui_child_height - 48,36,36, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\odbcad32.bmp")
GUICtrlSetTip(-1,"Microsoft DATA Access ODBC Administrator starten?")
GUICtrlSetCursor(-1, 0)
Global $Drive_button13 = GUICtrlCreateButton("", 577,$gui_child_height - 48,36,36, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\perfmon.bmp")
GUICtrlSetTip(-1,"Performance Monitor starten?")
GUICtrlSetCursor(-1, 0)
Global $Drive_button14 = GUICtrlCreateButton("", 623,$gui_child_height - 48,36,36, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\services.bmp")
GUICtrlSetTip(-1,"Windows Dienste starten?")
GUICtrlSetCursor(-1, 0)
Global $Drive_button15 = GUICtrlCreateButton("", 669,$gui_child_height - 48,36,36, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\control.bmp")
GUICtrlSetTip(-1,"Windows Systemsteuerung starten?")
GUICtrlSetCursor(-1, 0)
Global $Version_button = GUICtrlCreateButton("", 715,$gui_child_height - 48,36,36, $BS_BITMAP)
GUICtrlSetImage (-1, @ScriptDir & "\Setup\Button_Pics\info.bmp")
GUICtrlSetTip(-1,"Infos zum PC anzeigen")
GUICtrlSetCursor(-1, 0);####################################################################################################
; Definieren der Button Anweisungen:
;#####################################################################################################
; Anweisungen für die Buttons:
;-----------------------------
While 1
$msg = GUIGetMsg(1)
Select
;Programm beenden:
Case $msg[0] = $GUI_EVENT_CLOSE Or $msg[0] = $Exit_button
SoundPlay(@ScriptDir & "\Setup\Button_Sound\winSpaceSysExit.wav")
DllCall ( "user32.dll", "int", "AnimateWindow", "hwnd", $main_GUI, "int", 1000, "long", 0x00050010 );implode
ExitLoop;Zu den einzelnen Fenstern wechseln:
;~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~;Zum Windows Fenster wechseln:
Case $msg[0] = $Haupt_Win_button
GUICtrlSetImage ($Haupt_Win_button, @ScriptDir & "\Setup\Button_Pics\button3.bmp")
SoundPlay(@ScriptDir & "\Setup\Button_Sound\Click1.wav")
Sleep(300)
_Switch($Haupt_GUI, $Win_GUI)
GUICtrlSetImage ($Haupt_Win_button, @ScriptDir & "\Setup\Button_Pics\button1.bmp")
$Ziel_GUI = $Win_GUI
GUICtrlSetState ($Back_button, $GUI_ENABLE)
GUICtrlSetState ($Passwort_button, $GUI_DISABLE)
;Zum Office Fenster wechseln:
Case $msg[0] = $Haupt_Office_button
GUICtrlSetImage ($Haupt_Office_button, @ScriptDir & "\Setup\Button_Pics\button3.bmp")
SoundPlay(@ScriptDir & "\Setup\Button_Sound\Click1.wav")
Sleep(300)
_Switch($Haupt_GUI, $Office_GUI)
GUICtrlSetImage ($Haupt_Office_button, @ScriptDir & "\Setup\Button_Pics\button1.bmp")
$Ziel_GUI = $Office_GUI
GUICtrlSetState ($Back_button, $GUI_ENABLE)
GUICtrlSetState ($Passwort_button, $GUI_DISABLE);Zum Software Fenster wechseln:
Case $msg[0] = $Haupt_Progs_button
GUICtrlSetImage ($Haupt_Progs_button, @ScriptDir & "\Setup\Button_Pics\button3.bmp")
SoundPlay(@ScriptDir & "\Setup\Button_Sound\Click1.wav")
Sleep(300)
_Switch($Haupt_GUI, $Progs_GUI)
GUICtrlSetImage ($Haupt_Progs_button, @ScriptDir & "\Setup\Button_Pics\button1.bmp")
$Ziel_GUI = $Progs_GUI
GUICtrlSetState ($Back_button, $GUI_ENABLE)
GUICtrlSetState ($Passwort_button, $GUI_DISABLE);Zum Passwort Fenster wechseln:
Case $msg[0] = $Passwort_button
SoundPlay(@ScriptDir & "\Setup\Button_Sound\Click1.wav")
$passwd = InputBox("Security Check", "Enter your password.", "", "*") ;Passwortabfrage
if $passwd = ("") then ;Passwort
_Switch($Haupt_GUI, $Passwort_GUI)
$Ziel_GUI = $Passwort_GUI
GUICtrlSetState ($Back_button, $GUI_ENABLE)
GUICtrlSetState ($Passwort_button, $GUI_DISABLE)
else
MsgBox(16, "", "Falsches" & @CRLF & "Passwort", 10) ;Falsches PW
EndIf
;Zurück zum Hauptmenü:
Case $msg[0] = $Back_button
SoundPlay(@ScriptDir & "\Setup\Button_Sound\Click1.wav")
_Switch($Ziel_GUI, $Haupt_GUI)
GUICtrlSetState ($Back_button, $GUI_DISABLE)
GUICtrlSetState ($Passwort_button, $GUI_ENABLE);Zum Drive-Kapazitätsfenster wechseln:
Case $msg[0] = $Haupt_Drive_button
SoundPlay(@ScriptDir & "\Setup\Button_Sound\Click1.wav")
_Switch($Haupt_GUI, $Drive_GUI)
_DriveStatus("FIXED", "Lokale Festplatten:")
$Ziel_GUI = $Drive_GUI
GUICtrlSetState ($Back_button, $GUI_ENABLE)
GUICtrlSetState ($Passwort_button, $GUI_DISABLE)
;#####################################################################################################;Die einzelnen Buttons:
;~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~;Info Button:
Case $msg[0] = $Info_button
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
MsgBox(64, "Info", "" &@Lf& "" &@Lf& "" &@Lf& "© 2007 by xxx", 10) ;Info;Serial Button:
Case $msg[0] = $Serial_button
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
Dim $Bin
$Bin = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion", "DigitalProductID")
DecodeProductKey($Bin)
MsgBox(64,"Aktuelle Seriennummer:","Ihre aktuelle Windows Seriennummer lautet:" &@Lf& "" &@Lf& $Result, 15)
$Result = ""
;Version Button:
Case $msg[0] = $Version_button
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
_Version()
Case $msg[0] = $Btn_expand
SoundPlay(@ScriptDir & "\Setup\Button_Sound\winSpaceDefault.wav")
_expand()
#cs
;Alles Auswählen Button:
Case $msg[0] = $Progs_button4
SoundPlay(@ScriptDir & "\Setup\Button_Sound\winSpaceDefault.wav")
_checked()
;Auswahl löschen Button:
Case $msg[0] = $Progs_button5
SoundPlay(@ScriptDir & "\Setup\Button_Sound\winSpaceDefault.wav")
_unchecked()
Case $msg[0] = $Brennen
SoundPlay(@ScriptDir & "\Setup\Button_Sound\winSpaceDefault.wav")
_brennchecked()
;Installieren Button:
Case $msg[0] = $Progs_button6
SoundPlay(@ScriptDir & "\Setup\Button_Sound\winSpaceDefault.wav")
install ( )
#ce
;#####################################################################################################;Drive optionen ausführen:
;-------------------------;Defragmentierung:
Case $msg[0] = $Drive_button1
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
$defrag = @WindowsDir & "\System32\dfrg.msc"
RunDos($defrag);Datenträgerbereinigung:
Case $msg[0] = $Drive_button2
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
$cleanmgr = @WindowsDir & "\System32\cleanmgr.exe"
Run($cleanmgr);BackUp erstellen:
Case $msg[0] = $Drive_button3
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
$backup = @WindowsDir & "\System32\ntbackup.exe"
Run($backup);Diskmanagement starten:
Case $msg[0] = $Drive_button4
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
$diskmgmt = @WindowsDir & "\System32\diskmgmt.msc"
RunDOS($diskmgmt);systemwiederherstellung starten:
Case $msg[0] = $Drive_button5
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
$restore = @WindowsDir & "\System32\Restore\rstrui.exe"
;MsgBox(0, "Info", $Key1 &@lf& $Key2)
Run($restore);Computerverwaltung starten:
Case $msg[0] = $Drive_button6
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
$compmgmt = @WindowsDir & "\System32\compmgmt.msc"
RunDOS($compmgmt);Gerätemanager starten:
Case $msg[0] = $Drive_button7
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
$devmgmt = @WindowsDir & "\System32\devmgmt.msc"
RunDOS($devmgmt);DirectX Diagnoseprogramm starten:
Case $msg[0] = $Drive_button8
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
$dxdiag = @WindowsDir & "\System32\dxdiag.exe"
Run($dxdiag);Registrierungs-Editor starten:
Case $msg[0] = $Drive_button9
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
$regedt32 = @WindowsDir & "\System32\regedt32.exe"
Run($regedt32);Explorer starten:
Case $msg[0] = $Drive_button10
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
$explorer = @WindowsDir & "\explorer.exe"
Run($explorer);CMD starten:
Case $msg[0] = $Drive_button11
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
$cmd = @WindowsDir & "\System32\cmd.exe"
Run($cmd);Microsoft DATA Access ODBC:
Case $msg[0] = $Drive_button12
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
$odbc = @WindowsDir & "\System32\odbcad32.exe"
Run($odbc);Performance Monitor starten:
Case $msg[0] = $Drive_button13
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
$perfmon = @WindowsDir & "\System32\perfmon.exe"
Run($perfmon);Windows Dienste starten:
Case $msg[0] = $Drive_button14
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
$services = @WindowsDir & "\System32\services.msc"
RunDOS($services);Systemsteuerung starten:
Case $msg[0] = $Drive_button15
SoundPlay(@ScriptDir & "\Setup\Button_Sound\High1.wav")
$control = @WindowsDir & "\System32\control.exe"
Run($control)EndSelect
WEndGUIDelete()
$array = 0Exit
;*******************************************************************************************************************************
; Definieren der verschiedenen Funktionen:
;=========================================;*******************************************************************************************************************************
;##################################################################################################################
;---------------------------------
; Funktion um Fenster zu wechseln:
;---------------------------------
Func _Switch($Ausgang, $ziel)
GUISetState(@SW_HIDE,$Ausgang)
GUISetState(@SW_SHOW,$ziel)
EndFunc;######################################################################################################################
;----------------------------------------------------------
;Funktion um die Laufwerkstatusse (Festplatten) anzuzeigen:
;----------------------------------------------------------Func _DriveStatus($Drive, $DriveTyp)
Dim $Drive1, $i, $total, $free, $used, $FileSys, $Label, $Status, $progress, $y, $y1
$Drive1 = DriveGetDrive( $Drive )
$y = $gui_child_height - 326
$y1 = $y + 21For $i = 1 to $Drive1[0]
$total = DriveSpaceTotal($Drive1[$i])
$free = DriveSpaceFree($Drive1[$i])
$used = $total - $free
$FileSys = DriveGetFileSystem($Drive1[$i])
$Label = DriveGetLabel($Drive1[$i])
$Status = DriveStatus($Drive1[$i])GUICtrlSetData($Drive_Label, $DriveTyp)
GuiCtrlCreateLabel($Drive1[$i], 25, $y, 40, 20, $SS_CENTER )
GUICtrlSetBkColor(-1,0xd4d4d4)
GUICtrlSetFont (-1,10, 400, 2)
GuiCtrlCreateLabel($Label, 70, $y, 100, 20)
GUICtrlSetBkColor(-1,0xd4d4d4)
GUICtrlSetFont (-1,10, 400, 2)
$progress = GuiCtrlCreateProgress(175, $y, 200, 20)
GuiCtrlSetData($progress, 100 * $used / DriveSpaceTotal($Drive1[$i]))
GuiCtrlCreateLabel($FileSys, 380, $y, 70, 20, $SS_CENTER)
GUICtrlSetBkColor(-1,0xd4d4d4)
GUICtrlSetFont (-1,10, 400, 2)
GuiCtrlCreateLabel(Round($total/1024,2) & " GB ", 455, $y, 85, 20, $SS_CENTER)
GUICtrlSetBkColor(-1,0xd4d4d4)
GUICtrlSetFont (-1,10, 400, 2)
GuiCtrlCreateLabel(Round($used/1024,2) & " GB ", 545, $y, 80, 20, $SS_CENTER)
GUICtrlSetBkColor(-1,0xd4d4d4)
GUICtrlSetFont (-1,10, 400, 2)
GuiCtrlCreateLabel(Round($free/1024,2) & " GB ", 630, $y, 80, 20, $SS_CENTER)
GUICtrlSetBkColor(-1,0xd4d4d4)
GUICtrlSetFont (-1,10, 400, 2)
GuiCtrlCreateLabel($Status, 715, $y, 70, 20, $SS_CENTER)
GUICtrlSetBkColor(-1,0xd4d4d4)
GUICtrlSetFont (-1,10, 400, 2)
GUICtrlCreateLine(25, $y1, 783, $y1, 3, "0x000000")
GUICtrlCreateLine(66, $y-3, 66, $y1, 3, "0x000000")
GUICtrlCreateLine(171, $y-3, 171, $y1, 3, "0x000000")
GUICtrlCreateLine(376, $y-3, 376, $y1, 3, "0x000000")
GUICtrlCreateLine(451, $y-3, 451, $y1, 3, "0x000000")
GUICtrlCreateLine(541, $y-3, 541, $y1, 3, "0x000000")
GUICtrlCreateLine(626, $y-3, 626, $y1, 3, "0x000000")
GUICtrlCreateLine(711, $y-3, 711, $y1, 3, "0x000000")
$y = $y + 25
$y1 = $y + 21
NextEndFunc
;#####################################################################################################################
;---------------------------------
; Funktion um Linien zu erstellen:
;---------------------------------Func GUICtrlCreateLine($x1, $y1, $x2, $y2, $size, $color)
if $x1<>$x2 Then
$coeff_line = ( $y2-$y1 ) / ( $x2-$x1 )
$p = $y2 - ( $coeff_line * $x2 )
For $a = $x1 to $x2 step $size
GUICtrlSetBkColor(GUICtrlCreateLabel("", $a, ( $a * $coeff_line ) + $p, $size, $size), $color)
Next
Else
For $a = $y1 to $y2 step $size
GUICtrlSetBkColor(GUICtrlCreateLabel("", $x1, $a, $size, $size), $color)
Next
EndIf
EndFunc;---------------------------------------
; Funktion um ein Rechteck zu erstellen:
;---------------------------------------Func GUICtrlCreateEdge($x, $y, $width, $height, $color)
$edge= GUICtrlCreateLabel("", $x, $y, $width, $height, 0x1000)
GUICtrlSetBkColor($edge, $color)
EndFunc;##############################################################################################################################
;-----------------------------------------------
; Funktion zum Auslesen des Windows Product Key:
;-----------------------------------------------Func DecodeProductKey($BinaryDPID)
Local $bKey[15]
Local $sKey[29]
Local $Digits[24]
Local $Value = 0
Local $hi = 0
Local $n = 0
Local $i = 0
Local $dlen = 29
Local $slen = 15
Global $Result$Digits = StringSplit("BCDFGHJKMPQRTVWXY2346789", "")
$binaryDPID = StringMid($binaryDPID, 105, 30)
For $i = 1 To 29 Step 2
$bKey[Int($i / 2) ] = Dec(StringMid($binaryDPID, $i, 2))
NextFor $i = $dlen - 1 To 0 Step - 1
If Mod( ($i + 1), 6) = 0 Then
$sKey[$i] = "-"
Else
$hi = 0
For $n = $slen - 1 To 0 Step - 1
$Value = BitOR(BitShift($hi, -8), $bKey[$n])
$bKey[$n] = Int($Value / 24)
$hi = Mod($Value, 24)
Next
$sKey[$i] = $Digits[$hi + 1]
EndIfNext
For $i = 0 To 28
$Result = $Result & $sKey[$i]
NextReturn $Result
EndFunc
;#####################################################################################################
;----------------------------------------------
; Funktionen für den I-Button für Infos zum BS:
;----------------------------------------------
Func _Language()
Select
Case StringInStr("0413,0813", @OSLang)
Return "Irländisch"Case StringInStr("0409,0809,0c09,1009,1409,1809,1c09,2009,2409,2809,2c09,3009,3409", @OSLang)
Return "Englisch"Case StringInStr("040c,080c,0c0c,100c,140c,180c", @OSLang)
Return "Französisch"Case StringInStr("0407,0807,0c07,1007,1407", @OSLang)
Return "Deutsch"Case StringInStr("0410,0810", @OSLang)
Return "Italienisch"Case StringInStr("0414,0814", @OSLang)
Return "Norwegisch"Case StringInStr("0415", @OSLang)
Return "Polnisch"Case StringInStr("0416,0816", @OSLang)
Return "Portugisisch"Case StringInStr("040a,080a,0c0a,100a,140a,180a,1c0a,200a,240a,280a,2c0a,300a,340a,380a,3c0a,400a,440a,480a,4c0a,500a", @OSLang)
Return "Spanisch"Case StringInStr("041d,081d", @OSLang)
Return "Schwedisch"Case Else
Return "Ander Sprache"EndSelect
EndFuncFunc _OSVersion()
Select
Case @OSVersion == "WIN_2003"
Return "Windows 2003"
Case @OSVersion == "WIN_XP"
Return "Windows XP"
Case @OSVersion == "WIN_2000"
Return "Windows 2000"
Case @OSVersion == "WIN_NT4"
Return "Windows NT 4"
Case @OSVersion == "WIN_ME"
Return "Windows ME"
Case @OSVersion == "WIN_98"
Return "Windows 98"
Case @OSVersion == "WIN_95"
Return "Windows 95"
EndSelect
EndFuncFunc _OSTyp()
Select
Case @OSType == "WIN32_NT"
Return "Windows NT32"
Case @OSType == "WIN32_WINDOWS"
Return "Windows 32"
EndSelect
EndFuncFUNC _zounds($soundcardkey)
global $string
$i = 1
While 1
$key = RegEnumKey($soundcardkey, $i)
If @error = -1 Then ExitLoop
$reg = RegRead($soundcardkey & "\" & $key,"SetupPreferredAudioDevicesCount")
If $reg = "0" then
$reg = "0"
endif
If $reg = "" then
$reg = "-1"
endif$string = $string & $reg & " | "
seterror(1)$i = $i + 1
WEnd
return $string
endfuncFUNC _subkey($str)
$array = stringsplit( $str, "|")
_arraydelete ($array, 0)
$arrayoriginal = $array
$maxinda = _arraymaxindex($arrayoriginal, 1)
$maxa = $arrayoriginal[$maxinda]
_arraydelete ($array, $maxinda)
$arrayafter = $array
$maxindb = _arraymaxindex($arrayafter, 1)
$maxb = $arrayafter[$maxindb]If $maxinda = 0 AND $maxa = -1 then
$subkeyone = "0000"
$subkeytwo = "0000"
return $subkeyone & "|" & $subkeytwo
endifIf $maxindb = 0 AND $maxb = -1 then
If $maxinda < 10 then
$subkeyone = "000" & $maxinda
$subkeytwo = $subkeyone
endif
If $maxinda > 9 then
$subkeyone = "00" & $maxinda
$subkeytwo = $subkeyone
endif
return $subkeyone & "|" & $subkeytwo
endif
IF $maxinda < 10 AND $maxindb < 9 AND $maxinda < $maxindb then
$subkeyone = "000" & $maxinda
$subkeytwo = "000" & ($maxindb + 1)
endif
IF $maxinda < 10 AND $maxindb < 10 AND $maxinda > $maxindb then
$subkeyone = "000" & $maxinda
$subkeytwo = "000" & $maxindb
endif
IF $maxinda > 9 AND $maxindb > 9 AND $maxinda > $maxindb then
$subkeyone = "00" & $maxinda
$subkeytwo = "00" & $maxindb
endif
IF $maxinda > 9 AND $maxindb > 8 AND $maxinda < $maxindb then
$subkeyone = "00" & $maxinda
$subkeytwo = "00" & ($maxindb + 1)
endif
IF $maxinda > 9 AND $maxindb < 10 AND $maxinda > $maxindb then
$subkeyone = "00" & $maxinda
$subkeytwo = "000" & $maxindb
endif
If $maxinda < 10 AND $maxindb > 9 AND $maxinda < $maxindb then
$subkeyone = "000" & $maxinda
$subkeytwo = "00" & ($maxindb + 1)
endif
return $subkeyone & "|" &$subkeytwo
EndFuncFunc _Version()
Dim $cpugen, $cpuat, $cpuraw, $cpu, $mem, $memfreeun, $memtotalun, $memfree, $memtotal, $vide, $vidcard, $monito, $monitor, $soun, $soundcard, $mous, $mouse
;Infos zur CPU auslesen:
$cpugen = regRead("HKEY_LOCAL_MACHINE\HARDWARE\DESCRIPTION\System\CentralProcessor\0", "processornamestring")
$cpuat = " @ " ®Read("HKEY_LOCAL_MACHINE\HARDWARE\DESCRIPTION\System\CentralProcessor\0", "~MHz") & "MHz"
$cpuraw = $cpugen & $cpuat
$cpu = StringStripWS($cpuraw, 1);Infos zum Arbeitsspeicher:
$mem = memgetstats( )
$memfreeun = ($mem[2] / 1000)
$memtotalun = ($mem[1] / 1000)
$memfree = round($memfreeun, 0) & " MB"
$memtotal = round($memtotalun, 0) & " MB";CurrentControlSet auslesen:
global $crtset
$crtset = RegEnumKey ( "HKEY_LOCAL_MACHINE\SYSTEM", 1);Grafikkarte auslesen:
$vide = "HKEY_LOCAL_MACHINE\SYSTEM\" & $crtset & "\Control\Class\{4D36E968-E325-11CE-BFC1-08002BE10318}\0000"
$vidcard = regread ( $vide , "driverdesc" );Monitor auslesen:
$monito = "HKEY_LOCAL_MACHINE\SYSTEM\" & $crtset & "\Control\Class\{4D36E96E-E325-11CE-BFC1-08002BE10318}\0000"
$monitor = regread ($monito, "driverdesc");Soundkarte auslesen:
$string = _zounds("HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Class\{4D36E96C-E325-11CE-BFC1-08002BE10318}")
Dim $subkeystring
$subkeystring = _subkey($string)
$subarray = stringsplit($subkeystring, "|")$soun = "HKEY_LOCAL_MACHINE\SYSTEM\" & $crtset & "\Control\Class\{4D36E96C-E325-11CE-BFC1-08002BE10318}\" & $subarray[1]
$soundcardone = "Soundkarte: " & regread ( $soun, "driverdesc")$sountwo = "HKEY_LOCAL_MACHINE\SYSTEM\" & $crtset & "\Control\Class\{4D36E96C-E325-11CE-BFC1-08002BE10318}\" & $subarray[2]
$soundcardtwo = "Soundkarte: " & regread ( $sountwo, "driverdesc")If $soundcardone = $soundcardtwo then
$soundcard = $soundcardone
endif
If $soundcardtwo <> $soundcardone and regread ( $sountwo, "driverdesc") <> "" then
$soundcard = $soundcardone & @crlf & $soundcardtwo
endif
If $soundcardtwo <> $soundcardone and regread ( $sountwo, "driverdesc") = "" then
$soundcard = $soundcardone
endif;Mouse auslesen:
$mous = "HKEY_LOCAL_MACHINE\SYSTEM\" & $crtset & "\Control\Class\{4D36E96F-E325-11CE-BFC1-08002BE10318}\0000"
$mouse = regread ($mous, "driverdesc")MsgBox(64, "Infos zum PC:", "Hardware:" &@Lf& "CPU: " & $cpu &@Lf& "Arbeitsspeicher (gesammt/frei): " & $memtotal &"/"& $memfree & @LF & "Grafikkarte: " & $vidcard &@Lf& "Monitor: " & $monitor &@Lf& "Auflösung: " & @DesktopWidth & " x " & @DesktopHeight & " x " & @DesktopDepth &@LF& $soundcard &@LF& "Mouse: " & $mouse &@LF& " " &@LF& "Aktuelles Beriebssystem:" &@Lf& "Windows-Version: " & _OSVersion() & " " & @OSBuild & " " & @OSServicePack &@Lf& "Windows-Typ: "& _OSTyp() &@Lf& "Sprache: " & _Language() &@Lf& " " &@Lf& "Systeminformationen:" &@Lf& "Computer-Name: " & @ComputerName &@Lf& "Aktueller Benutzer: " & @UserName &@Lf& " " &@Lf& "Netzwerkinformationen:" &@Lf&"IP-Adresse 1: " & @IPAddress1 &@Lf& "IP-Adresse 2: " & @IPAddress2 &@Lf& "IP-Adresse 3: " & @IPAddress3 &@Lf& "IP-Adresse 4: " & @IPAddress4, 30)
EndFuncFunc _ArrayDelete(ByRef $avArray, $iElement)
Local $iCntr = 0, $iUpper = 0, $iNewSize = 0If (Not IsArray($avArray)) Then
SetError(1)
Return ""
EndIfLocal $iUpper = UBound($avArray)
If $iUpper = 1 Then
SetError(2)
Return ""
EndIfLocal $avNewArray[$iUpper - 1]
If $iElement < 0 Then
$iElement = 0
EndIf
If $iElement > ($iUpper - 1) Then
$iElement = ($iUpper - 1)
EndIf
If $iElement > 0 Then
For $iCntr = 0 To $iElement - 1
$avNewArray[$iCntr] = $avArray[$iCntr]
Next
EndIf
If $iElement < ($iUpper - 1) Then
For $iCntr = ($iElement + 1) To ($iUpper - 1)
$avNewArray[$iCntr - 1] = $avArray[$iCntr]
Next
EndIf
$avArray = $avNewArray
SetError(0)
Return 1
EndFuncFunc _ArrayMaxIndex($avArray, $iCompNumeric = 0, $i_Base = 0)
Local $iCntr, $iMaxIndex = $i_BaseIf Not IsArray($avArray) Then
SetError(1)
Return ""
EndIfLocal $iUpper = UBound($avArray)
For $iCntr = $i_Base To ($iUpper - 1)
If $iCompNumeric = 1 Then
If Number($avArray[$iMaxIndex]) < Number($avArray[$iCntr]) Then
$iMaxIndex = $iCntr
EndIf
Else
If $avArray[$iMaxIndex] < $avArray[$iCntr] Then
$iMaxIndex = $iCntr
EndIf
EndIf
Next
SetError(0)
Return $iMaxIndex
EndFuncSoftware-Installationsbereich
[autoit]; Software - Installationsfenster:
[/autoit][autoit][/autoit][autoit]
;---------------------------------
Global $Progs_GUI = GUICreate("",$gui_width,$gui_child_height,0,0,$WS_CHILD,-1,$main_GUI)
$Pic_Progs = GUICtrlCreatePic(@ScriptDir & "\Setup\Pics\software.jpg",-1,-1, 800, 600, $WS_EX_TRANSPARENT )
GUICtrlSetFont(-1,14,600); Erstellen der Buttons:
[/autoit][autoit][/autoit][autoit]
;-----------------------
#cs
Global $Progs_button4 = GUICtrlCreateButton("Alles auswählen",($gui_width -600) / 2,$gui_child_height - 38,90,30)
GUICtrlSetTip(-1,"Alle Programme auwählen?")
GUICtrlSetCursor(-1, 0)
Global $Progs_button5 = GUICtrlCreateButton("Auswahl löschen",($gui_width -400) / 2,$gui_child_height - 38,90,30)
GUICtrlSetTip(-1,"Alle gewählten Programme wieder entfernen?")
GUICtrlSetCursor(-1, 0)
#ce
Global $Progs_button6 = GUICtrlCreateButton("Installieren",($gui_width -200) / 2,$gui_child_height - 38,90,30)
GUICtrlSetTip(-1,"Die ausgewählten Programme installieren?")
GUICtrlSetCursor(-1, 0)$expand = 0
[/autoit][autoit][/autoit][autoit]
$text1 = "Ausklappen"
$text2 = "Einklappen"
Global $Btn_expand = GUICtrlCreateButton($text1,($gui_width -600) / 2,$gui_child_height - 38,90,30)
GUICtrlSetTip(-1,"Ausklappen und Einklappen?")
GUICtrlSetCursor(-1, 0)
GUICtrlSetOnEvent(-1, "_expand")$switch = 0
[/autoit][autoit][/autoit][autoit]
$text3 = "Alle wählen"
$text4 = "Wahl aufheben"
Global $Btn_all = GUICtrlCreateButton($text3,($gui_width -400) / 2,$gui_child_height - 38,90,30)
GUICtrlSetTip(-1,"Alle wählen und Wahl aufheben?")
GUICtrlSetCursor(-1, 0)
GUICtrlSetOnEvent(-1, "_all");Erstellen des TreeView:
[/autoit][autoit][/autoit][autoit]
;-----------------------
Global $nTV = GUICtrlCreateTreeView (($gui_width -600) / 2,$gui_child_height - 370,300,215,BitOr($TVS_HASBUTTONS,$TVS_HASLINES,$TVS_LINESATROOT,$TVS_DISABLEDRAGDROP,$TVS_SHOWSELALWAYS,$TVS_CHECKBOXES),$WS_EX_TRANSPARENT )
GUICtrlSetBkColor(-1,0xFFFFFF)
GUICtrlSetFont (-1,10, 400, 2)
GUICtrlSetCursor(-1, 0)
;Erstellen der TreeView-Labels und Icons:
;----------------------------------------
$nItem1 = GUICtrlCreateTreeViewItem("Messenger", $nTV)
GUICtrlSetColor(-1, 0xFF0000)
GUICtrlSetImage(-1, "explorer.exe", 0)
$nItem2 = GUICtrlCreateTreeViewItem("Internet", $nTV)
GUICtrlSetColor(-1, 0xFF00FF)
$nItem3 = GUICtrlCreateTreeViewItem("Tools", $nTV)
GUICtrlSetColor(-1, 0xFF8C00)
$nItem4 = GUICtrlCreateTreeViewItem("Mediaplayer", $nTV)
GUICtrlSetColor(-1, 0x00BFFF)
$nSubItem1 = GUICtrlCreateTreeViewItem("InterCafe Client", $nItem1)
GUICtrlSetImage(-1, "regedit.exe", 0)
$nSubItem2 = GUICtrlCreateTreeViewItem("ICQ 5.1", $nItem1)
GUICtrlSetImage(-1, "regedit.exe", 0)
$nSubItem3 = GUICtrlCreateTreeViewItem("Opera", $nItem2)
GUICtrlSetImage(-1, "regedit.exe", 0)
$nSubItem4 = GUICtrlCreateTreeViewItem("Mozilla Firefox 2", $nItem2)
GUICtrlSetImage(-1, "regedit.exe", 0)
$nSubItem5 = GUICtrlCreateTreeViewItem("Adobe Reader", $nItem3)
GUICtrlSetImage(-1, "regedit.exe", 0)
$nSubItem6 = GUICtrlCreateTreeViewItem("WinRar", $nItem3)
GUICtrlSetImage(-1, "regedit.exe", 0)
$nSubItem7 = GUICtrlCreateTreeViewItem("VLC Player", $nItem4)
GUICtrlSetImage(-1, "regedit.exe", 0)
$nSubItem8 = GUICtrlCreateTreeViewItem("QuickTime Player", $nItem4)
GUICtrlSetImage(-1, "regedit.exe", 0)
$nSubItem9 = GUICtrlCreateTreeViewItem("Media Player 11", $nItem4)
GUICtrlSetImage(-1, "regedit.exe", 0)Func _expand()
[/autoit][autoit][/autoit][autoit]
If $expand = 0 Then
;_GUICtrlTreeViewExpand($nTV)
$expand = 1
GUICtrlSetData($Btn_expand, $text2)
Else
;_GUICtrlTreeViewExpand($nTV, 0)
$expand = 0
GUICtrlSetData($Btn_expand, $text1)
EndIf
EndFuncFunc _all()
[/autoit]
If $switch = 0 Then
;SelectFull()
$switch = 1
GUICtrlSetData($Btn_all, $text4)
Else
;ReSelect()
$switch = 0
GUICtrlSetData($Btn_all, $text3)
EndIf
EndFunc
Das Problem ist das ich die Funktionen :1.Ausklappen und Einklappen
2.Alle wählen und Wahl aufheben
3.Übergeordnete Checkbox z.B. Messenger zum an und abwählen der Messenger-Programme
4.Prüfen der Checkboxen für Installationnicht hinbekomme. :weinen: