Warum geht hier weder Ende noch Einstellungen? oO
Spoiler anzeigen
#cs
Titel: Stämme Timing Programm (1280x1024)
Autor: S. Schwaiger aka. Stuuuven
Datum: 04.03.09
-----------------------------------------
Beschreibung:
Ver. 1.01: 4Ag's getimt innerhalb 0,4sec
#ce
#Region Include
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#include <String.au3>
#include <DATE.au3>
#EndRegion
opt ("GUIOnEventMode", 1)
[/autoit] [autoit][/autoit] [autoit]#Region GUI
$guiCPL = GUICreate("Stämme Timing Tool - BETA", 800, 700, -1, -1)
GUISetOnEvent($GUI_EVENT_CLOSE, "guiCPLClose")
$MonthCal1 = GUICtrlCreateMonthCal("2009/"&@MON&"/"&@MDAY, 570, 59, 170, 161)
$start = GUICtrlCreateButton (" Ag's los ", 30, 500, 150, 150)
GUICtrlSetFont ($start, 20)
GUICtrlSetOnEvent ($start, "goag")
GUISetState(@SW_SHOW, $guiCPL)
GUICtrlCreateLabel (" Ver. 1.01 ", 744, 664)
Guictrlcreatelabel (" © Stuuuven-Productions ", 6, 664)
$sync = GUICtrlCreateButton ("Aktualisieren", 690, 19)
GUICtrlSetOnEvent ($sync, "_sync")
$uhr=GUICtrlCreateLabel("--:--:--", 575, 17, 100, 40)
GUICtrlSetFont ($uhr, 20)
AdLibEnable("_clockRefresh")
;Menüs ======================================================
$Menu1 = GUICtrlCreateMenu("Projekte")
$M1_item1 = GUICtrlCreateMenuItem("Öffnen", $Menu1)
$M1_item2 = GUICtrlCreateMenuItem("Speichern", $Menu1)
$M1_item3 = GUICtrlCreateMenuItem("Ende", $Menu1)
$Menu2 = GUICtrlCreateMenu("Optionen")
$M2_item1 = GUICtrlCreateMenuItem("Einstellungen", $Menu2)
;=============================================================
;Felder ======================================================
$Group1 = GUICtrlCreateGroup(" Cleaner ", 30, 60, 90, 90)
$Group2 = GUICtrlCreateGroup(" 1 AG ", 30, 240, 90, 90)
$Group3 = GUICtrlCreateGroup(" 2 AG ", 220, 240, 90, 90)
$Group4 = GUICtrlCreateGroup(" 3 AG ", 410, 240, 90, 90)
$Group5 = GUICtrlCreateGroup(" 4 AG ", 600, 240, 90, 90)
;=============================================================
#EndRegion GUI
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $M1_item3
MsgBox(0,"a","a")
#Region Menü
Case $M1_item1
open()
Case $M1_item2
save()
case $M1_item3
off2()
Case $M2_item1
settings()
#EndRegion Menü
EndSwitch
WEnd
While (1)
Sleep (100)
WEnd
;DUMMY FUNCS==================================
Func save()
EndFunc
Func open()
EndFunc
;================================================
[/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]Func settings()
$sett = GUICreate (" Einstellungen", 150, 150, -1, -1)
$check1 = GUICtrlCreateCheckbox (" 1280x1024 ", 4, 10)
$check2 = GUICtrlCreateCheckbox (" 1600x1200 ", 4, 30)
$check3 = GUICtrlCreateCheckbox (" 800x600 ", 4, 50)
$Button = GUICtrlCreateButton("Installieren", 4, 75)
While 1
$msg = GUIGetMsg()
If $msg = $Button Then
$aufl1= GUICtrlRead($check1)
$aufl2= GUICtrlRead($check2)
$aufl3= GUICtrlRead($check3)
aufloesung_1($aufl1)
aufloesung_2($aufl2)
aufloesung_3($aufl3)
EndIf
If $msg = $GUI_EVENT_CLOSE Then ExitLoop
WEnd
GUISetState(@SW_SHOW, $sett)
EndFunc
Func _sync()
InetGet("http://www.uhrzeit.org/atomuhr.html","Uhrzeit.html",1)
$openfile = FileOpen("Uhrzeit.html",0)
$read_1 = FileRead($openfile)
FileClose($openfile)
FileDelete("Uhrzeit.html")
$gettime = _StringBetween($read_1,'<div id="anzeige">','</div>')
;~ GUICtrlSetData($Label1,$gettime[0])
$time = $gettime[0]
[/autoit] [autoit][/autoit] [autoit]$newtime = StringSplit($time,":")
[/autoit] [autoit][/autoit] [autoit]_SetTime($newtime[1],$newtime[2],$newtime[3])
[/autoit] [autoit][/autoit] [autoit]FileDelete("Uhrzeit.html")
EndFunc
Func _clockrefresh()
GUICtrlSetData($uhr,@HOUR & ":" & @MIN & ":" & @SEC)
EndFunc ;===> Uhrzeitrefresh
Func guiCPLClose()
Exit
EndFunc ;===> Close
Func goag()
GUISetState (@SW_HIDE, $guiCPL)
MouseClick ("left", 315, 414,1,0)
MouseClick ("left", 507, 414,1,0)
MouseClick ("left", 695, 414,1,0)
MouseClick ("left", 886, 414,1,0)
Sleep (1000)
GUISetState (@SW_SHOW, $guiCPL)
$close = GUICtrlCreateButton ("Schließen", 700, 600, 70, 40)
GUICtrlSetOnEvent ($close, "off")
EndFunc ;===> Ag's!
Func off()
Exit
EndFunc ;===> Close
Func off2()
Exit
EndFunc
;2nd Dummy=================================
Func aufloesung_1($aufl1)
EndFunc
Func aufloesung_2($aufl2)
EndFunc
Func aufloesung_3($aufl3)
EndFunc
;===========================================