Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <ButtonConstants.au3>
- #include <EditConstants.au3>
- #include <GUIConstantsEx.au3>
- #include <StaticConstants.au3>
- #include <WindowsConstants.au3>
- #Region ### START Koda GUI section ### Form=
- $form1 = GUICreate("Tarifsuchmaschine", 506, 125, 2608, 362)
- $name = GUICtrlCreateInput("Bitte Land eingeben...", 8, 40, 201, 21)
- $button1 = GUICtrlCreateButton("Such!", 8, 64, 201, 33)
- $label1 = GUICtrlCreateLabel("Bitte Land eingeben", 8, 16, 204, 17)
- $label2 = GUICtrlCreateLabel("", 232, 32, 164, 89)
- $Pic1 = GUICtrlCreatePic("", 416, 32, 73, 57)
- $us = GUICtrlCreateLabel("Deine Suche: ", 232, 8, 164, 17)
- GUISetState(@SW_SHOW)
- #EndRegion ### END Koda GUI section ###
- $var1="0"
- $Internet="0"
- $aufbau="0"
- $an="0"
- $ab="0"
- $inet="0"
- $sms = "0"
- $zahl = "0"
- $land= "0"
- While 1
- $nMsg = GUIGetMsg()
- Switch $nMsg
- Case $GUI_EVENT_CLOSE
- Exit
- Case $button1
- _lauf()
- _bilder()
- EndSwitch
- WEnd
- Func _lauf()
- _abkurz()
- If $zahl = "0" Then
- $zahl = IniRead("list.ini", "liste", GUICtrlRead($name),"false")
- $land = GuiCtrlRead($name)
- _suchen()
- _suchen2()
- If IniRead("list.ini", "internet", GUICtrlRead($name),"false") = "False" Then
- consolewrite(" Failed!")
- _ausgabe2()
- Elseif 1 then
- _ausgabe()
- Endif
- Else
- _suchen3()
- _suchen4()
- If IniRead("list.ini", "liste", $zahl,"false") = "False" Then
- consolewrite(" Failed!")
- _ausgabe2()
- Elseif 1 then
- _ausgabe()
- Endif
- EndIf
- EndFunc
- Func _suchen()
- $aufbau = IniRead("list.ini","tarif"&$zahl,"aufbau","fehlt")
- $an = IniRead("list.ini","tarif"&$zahl,"an","fehlt")
- $ab = IniRead("list.ini","tarif"&$zahl,"ab","fehlt")
- $sms = IniRead("list.ini","tarif"&$zahl,"sms","fehlt")
- consolewrite("suchen1 tarif"&$zahl&" ")
- EndFunc
- Func _suchen2()
- $zahl = IniRead("list.ini", "internet", GUICtrlRead($name),"false")
- $inet = IniRead("list.ini","inettar"&$zahl,"kosten","fehlt")
- consolewrite("suchen2 inettar"&$zahl&" ")
- endfunc
- Func _suchen3()
- $tar2 = IniRead("list.ini","liste",$zahl,"fehlt")
- $aufbau = IniRead("list.ini","tarif"&$tar2,"aufbau","fehlt")
- $an = IniRead("list.ini","tarif"&$tar2,"an","fehlt")
- $ab = IniRead("list.ini","tarif"&$tar2,"ab","fehlt")
- $sms = IniRead("list.ini","tarif"&$tar2,"sms","fehlt")
- consolewrite("suchen3 tarif"&$tar2&" ")
- EndFunc
- Func _suchen4()
- $tar = IniRead("list.ini","internet",$zahl,"fehlt")
- $land = $zahl
- $inet = IniRead("list.ini","inettar"&$tar,"kosten","fehlt")
- consolewrite("suchen4 inettar"&$tar&" ")
- endfunc
- func _bilder()
- GUICtrlSetImage($pic1,"")
- GUICtrlSetImage($pic1,"C:\Länderbilder\"&$land&".gif")
- EndFunc
- Func _abkurz()
- If IniRead("list.ini", "abkurz", GUICtrlRead($name),"false") <> "false" Then
- $zahl = iniRead("list.ini","abkurz", GUICtrlRead($name),"false")
- Else
- $zahl = "0"
- Endif
- EndFunc
- Func _ausgabe()
- GuiCtrlSetData($label2,"Fixkosten:" & @TAB &$aufbau & "€" & @CRLF & "Ankommend:" &@TAB& $an & "€ / Minute" & @CRLF & "Abgehend:" &@TAB& $ab& "€ / Minute" & @CRLF& "SMS:" & @TAB &@TAB& $sms & "€"& @CRLF & "Daten:"&@TAB&@TAB& $inet & "€ /50kb")
- GuiCtrlSetData($us,"Deine Suche: "&$land)
- Consolewrite(" Deine Suche:"&$land)
- endfunc
- Func _ausgabe2()
- GuiCtrlSetData($label2,"Land nicht gefunden!"& @CRLF & "Bitte Eingabe überprüfen")
- EndFunc
Add Comment
Please, Sign In to add comment