1. Dashboard
  2. Mitglieder
    1. Letzte Aktivitäten
    2. Benutzer online
    3. Team
    4. Mitgliedersuche
  3. Forenregeln
  4. Forum
    1. Unerledigte Themen
  • Anmelden
  • Registrieren
  • Suche
Alles
  • Alles
  • Artikel
  • Seiten
  • Forum
  • Erweiterte Suche
  1. AutoIt.de - Das deutschsprachige Forum.
  2. Mitglieder
  3. kra88

Beiträge von kra88

  • Webseite auf Erreichbarkeit testen - aber ohne Ping

    • kra88
    • 28. Januar 2014 um 19:05

    tcp, winhttp, webtcp, ie, ff...

  • Firefox starten und Button drücken

    • kra88
    • 4. Oktober 2013 um 09:30

    hier bekommst du das Addon her
    Mozrepl

    Die ff.au3 kopierst du in den Include Ordner (Installationsverzeichnis von Autoit).
    z.b

    Code
    C:\Programme\AutoIt3\Include
  • Koda Formdesigner Frage!

    • kra88
    • 4. Oktober 2013 um 07:49
    Spoiler anzeigen
    [autoit]


    #include <ButtonConstants.au3>
    #include <EditConstants.au3>
    #include <GUIConstantsEx.au3>
    #include <WindowsConstants.au3>

    [/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]

    #Region ### START Koda GUI section ### Form=
    $Form1 = GUICreate("Form1", 403, 405, 190, 121, BitOR($WS_MAXIMIZEBOX,$WS_MINIMIZEBOX,$WS_SIZEBOX,$WS_THICKFRAME,$WS_SYSMENU,$WS_CAPTION,$WS_OVERLAPPEDWINDOW,$WS_TILEDWINDOW,$WS_POPUP,$WS_POPUPWINDOW,$WS_GROUP,$WS_TABSTOP,$WS_BORDER,$WS_CLIPSIBLINGS))
    $bt_start = GUICtrlCreateButton("Button1", 200, 0, 201, 121, BitOR($BS_CENTER,$BS_PUSHLIKE))
    $bt_stop = GUICtrlCreateButton("Button2", 0, 0, 201, 121, $WS_GROUP)
    $bt_ausgabe = GUICtrlCreateButton("Button3", 0, 120, 201, 121, $WS_GROUP)
    $ed_ausgabe = GUICtrlCreateEdit("", 0, 240, 201, 153)
    GUICtrlSetData(-1, "Edit1")
    GUISetState(@SW_SHOW)
    #EndRegion ### END Koda GUI section ###

    [/autoit] [autoit][/autoit] [autoit]

    While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
    Case $GUI_EVENT_CLOSE
    Exit
    Case $Button1
    ;hier dein code für den button
    MsgBox(0,"Test","test")
    Case $Button2
    ; hier wieder der code bzw. eine funktion
    _test()
    Case $Button3
    GUICtrlSetData($Edit1,"neuer Text im Edit1")
    EndSwitch
    WEnd

    [/autoit] [autoit][/autoit] [autoit]

    func _test()
    MsgBox(0,"Test","test")
    EndFunc

    [/autoit]

    Schau dir Bitte erstmal die Grundlagen von Autoit an. In der Hilfe im Tutorial-Bereich und im Wiki, kann man sehr viel lernen.
    Wiki
    Online-Hilfe
    Forum.Tutorial

    Ich würde die Controlls noch anderst bezeichnen:

    [autoit]


    $bt_start = GUICtrlCreateButton("Start", 200, 0, 201, 121, BitOR($BS_CENTER,$BS_PUSHLIKE))
    $bt_stop = GUICtrlCreateButton("Stop", 0, 0, 201, 121, $WS_GROUP)
    $bt_ausgabe = GUICtrlCreateButton("Ausgabe", 0, 120, 201, 121, $WS_GROUP)
    $ed_ausgabe = GUICtrlCreateEdit("", 0, 240, 201, 153)

    [/autoit]
  • Xampp homepage installieren

    • kra88
    • 10. Dezember 2012 um 08:42

    Guten morgen zusammen.

    Nimm am besten den MYSQL Dumper den findest du hier http://www.mysqldumper.de/
    runterladen installieren und importieren

  • ListView - SubItem einzeln färben/formatieren, Finale Version! (v1.3)

    • kra88
    • 20. Juni 2012 um 21:53

    ich wollte eigentlich damit bezwecken, das die Buttons immer reagieren!

    Ich habe jetzt mal das wm_command zeug weggemacht. wenn ich jetzt auf den Button drück der die Funktion _test() hängt das Programm und wird beendet.
    wo liegt jetzt mein fehler?

    Spoiler anzeigen
    [autoit]


    #include <GuiListView.au3>
    #include <EditConstants.au3>
    #include 'LV_Format_include.au3'
    #include <GuiButton.au3>

    [/autoit] [autoit][/autoit] [autoit]

    Global $hLV,$GUI

    [/autoit] [autoit][/autoit] [autoit]

    $GUI = GUICreate('')
    $lv = GUICtrlCreateListView("Test1|Test2", 10, 10, 300, 150)
    $btn_hinzu = GUICtrlCreateButton( "hinzufügen", 10, 200, 90, 50)
    $btn_loesch = GUICtrlCreateButton( "lösche", 10, 250, 90, 50)

    [/autoit] [autoit][/autoit] [autoit]

    $hLV = GUICtrlGetHandle($lv)

    [/autoit] [autoit][/autoit] [autoit]

    $GUI_Format = GUICreate("Hinzüfgen", 239, 196, 331, 468)
    $Label1 = GUICtrlCreateLabel("1. Busfahrt", 8, 40, 55, 17)
    $Label5 = GUICtrlCreateLabel("Telekom", 8, 72, 45, 17)
    $Label9 = GUICtrlCreateLabel("2. Busfahrt", 8, 104, 55, 17)
    $chb_urlaub = GUICtrlCreateCheckbox("Urlaub", 8, 160, 65, 25)
    $Label2 = GUICtrlCreateLabel("Datum", 8, 136, 35, 17)
    $Start = GUICtrlCreateLabel("Start Zeit:", 80, 8, 50, 17)
    $Label3 = GUICtrlCreateLabel("End Zeit", 152, 8, 44, 17)
    $txt_bus1_start = GUICtrlCreateInput("06:00", 72, 32, 65, 21)
    $txt_bus1_ende = GUICtrlCreateInput("06:30", 152, 32, 65, 21)
    $txt_telekom_start = GUICtrlCreateInput("09:00", 72, 64, 65, 21)
    $txt_telekm_ende = GUICtrlCreateInput("16:00", 152, 64, 65, 21)
    $txt_bus2_start = GUICtrlCreateInput("17:00", 72, 96, 65, 21)
    $txt_bus2_ende = GUICtrlCreateInput("20:00", 152, 96, 65, 21)
    $txt_datum = GUICtrlCreateInput("1.1.2012", 72, 128, 145, 21)
    $bt_hinzufoegen_ = GUICtrlCreateButton("Hinzufügen", 72, 160, 145, 25)

    [/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]

    _GUICtrlListView_Formatting_Startup($GUI, $hLV)
    _GUICtrlListView_AddOrIns_Item($hLV, 'Test0|Test1'); funktioniert
    _GUICtrlListView_FormattingCell($hLV, 0, 0, 0xff0000, -1, -1, 600, 'Times New Roman'); funktioniert

    [/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]

    GUIRegisterMsg($WM_NOTIFY, "WM_NOTIFY")
    GUISetState(@SW_SHOW, $GUI)

    [/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]

    While 1
    $nMsg = GUIGetMsg(1)
    Switch $nMsg[0]
    Case $GUI_EVENT_CLOSE
    Switch $nMsg[1]
    Case $GUI ; User will das Hauptfenster schließen
    If MsgBox(32 + 4, "Beenden", "Wollen sie das Programm wirklich beenden?") = 6 Then Exit; wenn ja, dann End-Funktion aufrufen
    Case $GUI_Format ; User will das "Neuer Eintrag"-Fenster schließen
    GUISetState(@SW_HIDE,$GUI_Format)
    EndSwitch
    Case $btn_hinzu
    _bt_click_hinzufuegen()
    Case $bt_hinzufoegen_
    _test()

    [/autoit] [autoit][/autoit] [autoit]

    EndSwitch
    WEnd

    [/autoit] [autoit][/autoit] [autoit]

    func _bt_click_hinzufuegen()
    GUISetState(@SW_SHOW, $GUI_Format)
    EndFunc

    [/autoit] [autoit][/autoit] [autoit]

    func _test()
    _GUICtrlListView_AddOrIns_Item($hLV, 'Test0|Test1') ; ab hier hängt das programm und wird beendet
    _GUICtrlListView_FormattingCell($hLV, 1, 1, 0xff0000, -1, -1, 600, 'Times New Roman')
    EndFunc

    [/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]

    Func WM_NOTIFY($hWnd, $iMsg, $iwParam, $ilParam)
    Local $hWndFrom, $iCode, $tNMHDR
    $tNMHDR = DllStructCreate($tagNMHDR, $ilParam)
    $hWndFrom = HWnd(DllStructGetData($tNMHDR, "hWndFrom"))
    $iCode = DllStructGetData($tNMHDR, "Code")
    ; If ($hWndFrom = $hLV Or $hWndFrom = $hLV2) And $iCode = $NM_RCLICK Then _RightClick()
    Return $GUI_RUNDEFMSG
    EndFunc ;==>WM_NOTIFY

    [/autoit]

    ich bin langsam echt am verzweifel das musst doch mal endlich klappen

  • ListView - SubItem einzeln färben/formatieren, Finale Version! (v1.3)

    • kra88
    • 20. Juni 2012 um 21:05

    also hab es mal geändert:

    Spoiler anzeigen
    [autoit]


    #include <GuiListView.au3>
    #include <EditConstants.au3>
    #include 'LV_Format_include.au3'
    #include <GuiButton.au3>

    [/autoit] [autoit][/autoit] [autoit]

    Global $hLV,$GUI

    [/autoit] [autoit][/autoit] [autoit]

    $GUI = GUICreate('')
    $lv = GUICtrlCreateListView("Test1|Test2", 10, 10, 300, 150)
    $btn_hinzu = _GUICtrlButton_Create($GUI, "hinzufügen", 10, 200, 90, 50)
    $btn_loesch = _GUICtrlButton_Create($GUI, "lösche", 10, 250, 90, 50)

    [/autoit] [autoit][/autoit] [autoit]

    $hLV = GUICtrlGetHandle($lv)

    [/autoit] [autoit][/autoit] [autoit]

    $GUI_Format =GUICreate("Hinzüfgen", 239, 196, 331, 468)
    $Label1 = GUICtrlCreateLabel("1. Busfahrt", 8, 40, 55, 17)
    $Label5 = GUICtrlCreateLabel("Telekom", 8, 72, 45, 17)
    $Label9 = GUICtrlCreateLabel("2. Busfahrt", 8, 104, 55, 17)
    $chb_urlaub = GUICtrlCreateCheckbox("Urlaub", 8, 160, 65, 25)
    $Label2 = GUICtrlCreateLabel("Datum", 8, 136, 35, 17)
    $Start = GUICtrlCreateLabel("Start Zeit:", 80, 8, 50, 17)
    $Label3 = GUICtrlCreateLabel("End Zeit", 152, 8, 44, 17)
    $txt_bus1_start = GUICtrlCreateInput("06:00", 72, 32, 65, 21)
    $txt_bus1_ende = GUICtrlCreateInput("06:30", 152, 32, 65, 21)
    $txt_telekom_start = GUICtrlCreateInput("09:00", 72, 64, 65, 21)
    $txt_telekm_ende = GUICtrlCreateInput("16:00", 152, 64, 65, 21)
    $txt_bus2_start = GUICtrlCreateInput("17:00", 72, 96, 65, 21)
    $txt_bus2_ende = GUICtrlCreateInput("20:00", 152, 96, 65, 21)
    $txt_datum = GUICtrlCreateInput("1.1.2012", 72, 128, 145, 21)
    $bt_hinzufoegen_ = GUICtrlCreateButton("Hinzufügen", 72, 160, 145, 25)

    [/autoit] [autoit][/autoit] [autoit]

    ;das hier geht
    _GUICtrlListView_Formatting_Startup($GUI, $hLV)
    _GUICtrlListView_AddOrIns_Item($hLV, 'Test0|Test1'); funktioniert
    _GUICtrlListView_FormattingCell($hLV, 0, 0, 0xff0000, -1, -1, 600, 'Times New Roman'); funktioniert
    ;das hier geht

    [/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]

    GUIRegisterMsg($WM_COMMAND, "WM_COMMAND")
    GUIRegisterMsg($WM_NOTIFY, "WM_NOTIFY")
    GUISetState(@SW_SHOW, $GUI)

    [/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]

    While 1
    $msg = GUIGetMsg(1)
    Switch $msg[1]
    Case $GUI
    If $msg[0] = -3 Then ExitLoop
    Case $GUI_Format
    If $msg[0] = -3 Then
    GUISetState(@SW_HIDE, $GUI_Format)
    ;_setFormat()
    EndIf
    EndSwitch
    WEnd

    [/autoit] [autoit][/autoit] [autoit]

    func _bt_click_hinzufuegen()
    GUISetState(@SW_SHOW, $GUI_Format)
    EndFunc

    [/autoit] [autoit][/autoit] [autoit]

    func _test()
    ;_GUICtrlListView_Formatting_Startup($GUI, $hLV)
    _GUICtrlListView_AddOrIns_Item($hLV, 'Test0|Test1') ; ab hier hängt das programm und wird beendet
    _GUICtrlListView_FormattingCell($hLV, 0, 0, 0xff0000, -1, -1, 600, 'Times New Roman')
    EndFunc

    [/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]

    ; Reaktion auf einen Button-Klick
    Func WM_COMMAND($hWnd, $Msg, $wParam, $lParam)
    #forceref $hWnd, $Msg
    Local $nNotifyCode = BitShift($wParam, 16)
    Local $nID = BitAND($wParam, 0x0000FFFF)
    Local $hCtrl = $lParam
    Local $sText = ""
    ;if $lParam =
    Switch $hCtrl
    Case $btn_hinzu
    Switch $nNotifyCode
    Case $BN_CLICKED
    _bt_click_hinzufuegen()
    EndSwitch
    Case $btn_loesch
    Switch $nNotifyCode
    Case $BN_CLICKED
    msgbox(64,"test","Test")
    EndSwitch
    Case GUICtrlGetHandle($bt_hinzufoegen_)
    Switch $nNotifyCode
    Case $BN_CLICKED
    msgbox(64,"test","Test")
    _test()
    EndSwitch

    [/autoit] [autoit][/autoit] [autoit]

    Return 0 ; Nur bei Klick auf den Button
    EndSwitch
    ; Setzt die Standardverarbeitung der Autoit3-internen Nachrichtenkommandos fort.
    ; Man kann die Zeile auch weglassen.
    ; !!! Aber nur 'Return' (ohne jegliche Variable) wird die Verarbeitung der Standardnachrichten unterbinden !!!
    Return $GUI_RUNDEFMSG
    EndFunc ;==>WM_COMMAND

    [/autoit] [autoit][/autoit] [autoit]

    Func WM_NOTIFY($hWnd, $iMsg, $iwParam, $ilParam)
    Local $hWndFrom, $iCode, $tNMHDR
    $tNMHDR = DllStructCreate($tagNMHDR, $ilParam)
    $hWndFrom = HWnd(DllStructGetData($tNMHDR, "hWndFrom"))
    $iCode = DllStructGetData($tNMHDR, "Code")
    ; If ($hWndFrom = $hLV Or $hWndFrom = $hLV2) And $iCode = $NM_RCLICK Then _RightClick()
    Return $GUI_RUNDEFMSG
    EndFunc ;==>WM_NOTIFY

    [/autoit]

    Wenn ich die funktion _test() über WM_COMMAND($hWnd, $Msg, $wParam, $lParam) aufrufe, geht es nicht. Das Programm reagiert nicht mehr.
    Ich denke beim der Funktion WM_COMMAND($hWnd, $Msg, $wParam, $lParam) liegt das Problem.
    Leider versteh ich das nicht. Kannst du mir das erklären?
    das ich von zwei gui's die verschiedenen buttons klicken kann und dann item's und farbe ändern kann.

  • ListView - SubItem einzeln färben/formatieren, Finale Version! (v1.3)

    • kra88
    • 20. Juni 2012 um 20:28

    Hey Leute,
    ich habe ein Problem beim erstellen von items.

    hier mein code:

    Spoiler anzeigen
    [autoit]


    #include <GuiListView.au3>
    #include <EditConstants.au3>
    #include 'LV_Format_include.au3'
    #include <GuiButton.au3>

    [/autoit] [autoit][/autoit] [autoit]

    Global $hLV,$GUI

    [/autoit] [autoit][/autoit] [autoit]

    $GUI = GUICreate('')
    $lv = GUICtrlCreateListView("Test1|Test2", 10, 10, 300, 150)
    $btn_hinzu = _GUICtrlButton_Create($GUI, "hinzufügen", 10, 200, 90, 50)
    $btn_loesch = _GUICtrlButton_Create($GUI, "lösche", 10, 250, 90, 50)

    [/autoit] [autoit][/autoit] [autoit]

    $hLV = GUICtrlGetHandle($lv)

    [/autoit] [autoit][/autoit] [autoit]

    $GUI_Format =GUICreate("Hinzüfgen", 239, 196, 331, 468)
    $Label1 = GUICtrlCreateLabel("1. Busfahrt", 8, 40, 55, 17)
    $Label5 = GUICtrlCreateLabel("Telekom", 8, 72, 45, 17)
    $Label9 = GUICtrlCreateLabel("2. Busfahrt", 8, 104, 55, 17)
    $chb_urlaub = GUICtrlCreateCheckbox("Urlaub", 8, 160, 65, 25)
    $Label2 = GUICtrlCreateLabel("Datum", 8, 136, 35, 17)
    $Start = GUICtrlCreateLabel("Start Zeit:", 80, 8, 50, 17)
    $Label3 = GUICtrlCreateLabel("End Zeit", 152, 8, 44, 17)
    $txt_bus1_start = GUICtrlCreateInput("06:00", 72, 32, 65, 21)
    $txt_bus1_ende = GUICtrlCreateInput("06:30", 152, 32, 65, 21)
    $txt_telekom_start = GUICtrlCreateInput("09:00", 72, 64, 65, 21)
    $txt_telekm_ende = GUICtrlCreateInput("16:00", 152, 64, 65, 21)
    $txt_bus2_start = GUICtrlCreateInput("17:00", 72, 96, 65, 21)
    $txt_bus2_ende = GUICtrlCreateInput("20:00", 152, 96, 65, 21)
    $txt_datum = GUICtrlCreateInput("1.1.2012", 72, 128, 145, 21)
    $bt_hinzufoegen_ = GUICtrlCreateButton("Hinzufügen", 72, 160, 145, 25)

    [/autoit] [autoit][/autoit] [autoit]

    ;das hier geht
    _GUICtrlListView_Formatting_Startup($GUI, $hLV)
    _GUICtrlListView_AddOrIns_Item($hLV, 'Test0|Test1')
    _GUICtrlListView_FormattingCell($hLV, 0, 0, 0xff0000, -1, -1, 600, 'Times New Roman')
    ;das hier geht

    [/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]

    GUIRegisterMsg($WM_COMMAND, "WM_COMMAND")
    GUIRegisterMsg($WM_NOTIFY, "WM_NOTIFY")
    GUISetState(@SW_SHOW, $GUI)

    [/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]

    While 1
    $msg = GUIGetMsg(1)
    Switch $msg[1]
    Case $GUI
    If $msg[0] = -3 Then ExitLoop
    Case $GUI_Format
    If $msg[0] = -3 Then
    GUISetState(@SW_HIDE, $GUI_Format)
    ;_setFormat()
    EndIf
    EndSwitch
    WEnd

    [/autoit] [autoit][/autoit] [autoit]

    func _bt_click_hinzufuegen()
    GUISetState(@SW_SHOW, $GUI_Format)
    EndFunc

    [/autoit] [autoit][/autoit] [autoit]

    func _test()
    _GUICtrlListView_Formatting_Startup($GUI, $hLV)
    _GUICtrlListView_AddOrIns_Item($hLV, 'Test0|Test1')
    _GUICtrlListView_FormattingCell($hLV, 0, 0, 0xff0000, -1, -1, 600, 'Times New Roman')
    EndFunc

    [/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]

    ; Reaktion auf einen Button-Klick
    Func WM_COMMAND($hWnd, $Msg, $wParam, $lParam)
    #forceref $hWnd, $Msg
    Local $nNotifyCode = BitShift($wParam, 16)
    Local $nID = BitAND($wParam, 0x0000FFFF)
    Local $hCtrl = $lParam
    Local $sText = ""
    ;if $lParam =
    Switch $hCtrl
    Case $btn_hinzu
    Switch $nNotifyCode
    Case $BN_CLICKED
    _bt_click_hinzufuegen()
    EndSwitch
    Case $btn_loesch
    Switch $nNotifyCode
    Case $BN_CLICKED
    msgbox(64,"test","Test")
    EndSwitch
    Case GUICtrlGetHandle($bt_hinzufoegen_)
    Switch $nNotifyCode
    Case $BN_CLICKED
    msgbox(64,"test","Test")
    _test()
    EndSwitch

    [/autoit] [autoit][/autoit] [autoit]

    Return 0 ; Nur bei Klick auf den Button
    EndSwitch
    ; Setzt die Standardverarbeitung der Autoit3-internen Nachrichtenkommandos fort.
    ; Man kann die Zeile auch weglassen.
    ; !!! Aber nur 'Return' (ohne jegliche Variable) wird die Verarbeitung der Standardnachrichten unterbinden !!!
    Return $GUI_RUNDEFMSG
    EndFunc ;==>WM_COMMAND

    [/autoit] [autoit][/autoit] [autoit]

    Func WM_NOTIFY($hWnd, $iMsg, $iwParam, $ilParam)
    Local $hWndFrom, $iCode, $tNMHDR
    $tNMHDR = DllStructCreate($tagNMHDR, $ilParam)
    $hWndFrom = HWnd(DllStructGetData($tNMHDR, "hWndFrom"))
    $iCode = DllStructGetData($tNMHDR, "Code")
    ; If ($hWndFrom = $hLV Or $hWndFrom = $hLV2) And $iCode = $NM_RCLICK Then _RightClick()
    Return $GUI_RUNDEFMSG
    EndFunc ;==>WM_NOTIFY

    [/autoit]

    Ich kann z .b beim aufruf der Function _test() keine items erstellen.
    Wie muss ich den Code schreiben, damit ich aus jeder beliebigen Funktion items erstellen und die Farben ändern kann?
    zusätzlich will ich ab einem bestimmtem Wert (Subitem) die Farbe ändern.

  • Irgend was anderes als IE in einer Form?

    • kra88
    • 7. März 2012 um 07:33

    du könntest ja alles mit winhttp oder tcp machen. das ist viel schneller und braucht weniger resourcen

  • Rename Script für Serien

    • kra88
    • 6. März 2012 um 14:35

    wäre es auch möglcih das so zu machen?

    Ordner Serienname z.b Leverage
    ->Ordner Staffelname z.b S01, S02,S03
    -->Ordnername Episode Leverage.S03E01.Hinter.Gittern.German.Dubbed.DVDRip.XviD-ITG
    --->Dateiname soll dann Leverage.S03E01.Hinter.Gittern.German.Dubbed.DVDRip.XviD-ITG.avi

    so soltle es dann fertig aussehen:
    im ordner Leverage/S03/Leverage.S03E01.Hinter.Gittern.German.Dubbed.DVDRip.XviD-ITG.avi

    Evtl noch den restlichen müll löschen!

  • Stringregex Problem bei Livescore.com

    • kra88
    • 9. Januar 2012 um 14:56

    also wenn ich den code nehme:

    erhalte ichfolgenden fehlermeldung:

    Code
    : ==> Variable must be of type "Object".:
    For $i in StringRegExp($s_Source, $s_Pattern, 4)
    For $i in StringRegExp($s_Source, $s_Pattern, 4)^ ERROR
    ->14:53:31 AutoIT3.exe ended.rc:1

    [

    Spoiler anzeigen

    autoit]
    #include <Array.au3>

    Global Const $s_URL = "http://livescore.com/soccer/live/"
    Global Const $s_Source = _ConvertEntities(BinaryToString(InetRead($s_URL)))
    Global Const $s_Pattern = '(?s)(?x)<td\swidth="45"[^>]+>([^<]+?)</td> # Uhrzeitspalte' & @CRLF & _
    '<td\salign="right"[^>]+>([^<]+?)</td> # Heimmannschaftspalte' & @CRLF & _
    '<td\salign="center"[^>]+>(.+?)</td> # Ergebnisspalte' & @CRLF & _
    '<td\s[^>]+>(.+?)</td> # Gastmannschaftspalte'

    For $i in StringRegExp($s_Source, $s_Pattern, 4)
    _ArrayDisplay($i)
    Next


    ; #FUNCTION# ======================================================================================
    ; Name ..........: _ConvertEntities()
    ; Description ...: Wandelt HTML-Entitäten in einem Quellcode in ihre entsprechenden Zeichen
    ; Syntax ........: _ConvertEntities($sURL)
    ; Parameters ....: $s_S - String in welchem die Entitäten umgewandelt werden sollen
    ; Return values .: der bearbeitete String
    ; Author ........: AspirinJunkie
    ; =================================================================================================
    Func _ConvertEntities($s_S)
    Local $o_Dict = ObjCreate("Scripting.Dictionary")
    Local $a_RegExp, $s_T
    Local Static $a_NameEnt[253][2] = [["quot", 34],["amp", 38],["apos", 39],["lt", 60],["gt", 62],["quot", 34],["amp", 38],["apos", 39],["lt", 60],["gt", 62],["nbsp", 160], _
    ["iexcl", 161],["cent", 162],["pound", 163],["curren", 164],["yen", 165],["brvbar", 166],["sect", 167],["uml", 168],["copy", 169], _
    ["ordf", 170],["laquo", 171],["not", 172],["reg", 174],["macr", 175],["deg", 176],["plusmn", 177],["sup2", 178],["sup3", 179], _
    ["acute", 180],["micro", 181],["para", 182],["middot", 183],["cedil", 184],["sup1", 185],["ordm", 186],["raquo", 187], _
    ["frac14", 188],["frac12", 189],["frac34", 190],["iquest", 191],["Agrave", 192],["Aacute", 193],["Acirc", 194],["Atilde", 195], _
    ["Auml", 196],["Aring", 197],["AElig", 198],["Ccedil", 199],["Egrave", 200],["Eacute", 201],["Ecirc", 202],["Euml", 203], _
    ["Igrave", 204],["Iacute", 205],["Icirc", 206],["Iuml", 207],["ETH", 208],["Ntilde", 209],["Ograve", 210],["Oacute", 211], _
    ["Ocirc", 212],["Otilde", 213],["Ouml", 214],["times", 215],["Oslash", 216],["Ugrave", 217],["Uacute", 218],["Ucirc", 219], _
    ["Uuml", 220],["Yacute", 221],["THORN", 222],["szlig", 223],["agrave", 224],["aacute", 225],["acirc", 226],["atilde", 227], _
    ["auml", 228],["aring", 229],["aelig", 230],["ccedil", 231],["egrave", 232],["eacute", 233],["ecirc", 234],["euml", 235], _
    ["igrave", 236],["iacute", 237],["icirc", 238],["iuml", 239],["eth", 240],["ntilde", 241],["ograve", 242],["oacute", 243],["ocirc", 244], _
    ["otilde", 245],["ouml", 246],["divide", 247],["oslash", 248],["ugrave", 249],["uacute", 250],["ucirc", 251],["uuml", 252],["yacute", 253], _
    ["thorn", 254],["yuml", 255],["OElig", 338],["oelig", 339],["Scaron", 352],["scaron", 353],["Yuml", 376],["fnof", 402],["circ", 710], _
    ["tilde", 732],["Alpha", 913],["Beta", 914],["Gamma", 915],["Delta", 916],["Epsilon", 917],["Zeta", 918],["Eta", 919],["Theta", 920], _
    ["Iota", 921],["Kappa", 922],["Lambda", 923],["Mu", 924],["Nu", 925],["Xi", 926],["Omicron", 927],["Pi", 928],["Rho", 929],["Sigma", 931], _
    ["Tau", 932],["Upsilon", 933],["Phi", 934],["Chi", 935],["Psi", 936],["Omega", 937],["alpha", 945],["beta", 946],["gamma", 947], _
    ["delta", 948],["epsilon", 949],["zeta", 950],["eta", 951],["theta", 952],["iota", 953],["kappa", 954],["lambda", 955],["mu", 956], _
    ["nu", 957],["xi", 958],["omicron", 959],["pi", 960],["rho", 961],["sigmaf", 962],["sigma", 963],["tau", 964],["upsilon", 965], _
    ["phi", 966],["chi", 967],["psi", 968],["omega", 969],["thetasym", 977],["upsih", 978],["piv", 982],["ensp", 8194], _
    ["emsp", 8195],["thinsp", 8201],["ndash", 8211],["mdash", 8212],["lsquo", 8216],["rsquo", 8217],["sbquo", 8218], _
    ["ldquo", 8220],["rdquo", 8221],["bdquo", 8222],["dagger", 8224],["Dagger", 8225],["bull", 8226],["hellip", 8230], _
    ["permil", 8240],["prime", 8242],["Prime", 8243],["lsaquo", 8249],["rsaquo", 8250],["oline", 8254],["frasl", 8260], _
    ["euro", 8364],["image", 8465],["weierp", 8472],["real", 8476],["trade", 8482],["alefsym", 8501],["larr", 8592], _
    ["uarr", 8593],["rarr", 8594],["darr", 8595],["harr", 8596],["crarr", 8629],["lArr", 8656],["uArr", 8657],["rArr", 8658], _
    ["dArr", 8659],["hArr", 8660],["forall", 8704],["part", 8706],["exist", 8707],["empty", 8709],["nabla", 8711],["isin", 8712], _
    ["notin", 8713],["ni", 8715],["prod", 8719],["sum", 8721],["minus", 8722],["lowast", 8727],["radic", 8730],["prop", 8733],["infin", 8734], _
    ["ang", 8736],["and", 8743],["or", 8744],["cap", 8745],["cup", 8746],["int", 8747],["there4", 8756],["sim", 8764],["cong", 8773], _
    ["asymp", 8776],["ne", 8800],["equiv", 8801],["le", 8804],["ge", 8805],["sub", 8834],["sup", 8835],["nsub", 8836],["sube", 8838], _
    ["supe", 8839],["oplus", 8853],["otimes", 8855],["perp", 8869],["sdot", 8901],["lceil", 8968],["rceil", 8969],["lfloor", 8970],["rfloor", 8971], _
    ["lang", 10216],["rang", 10217],["loz", 9674],["spades", 9824],["clubs", 9827],["hearts", 9829],["diams", 9830]]

    ; Dezimalform:
    $a_RegExp = StringRegExp($s_S, "&#(\d{2,4});", 3)
    If IsArray($a_RegExp) And Not @error Then
    For $i In $a_RegExp
    $o_Dict("&#" & $i & ";") = Number($i)
    Next
    EndIf
    ; Hexadezimalform:
    $a_RegExp = StringRegExp($s_S, "&#x([[:xdigit:]]{2,4});", 3)
    If IsArray($a_RegExp) And Not @error Then
    For $i In $a_RegExp
    $o_Dict("&#x" & $i & ";") = Dec($i)
    Next
    EndIf
    ; Namensform:
    For $i = 0 To 252
    $s_T = "&" & $a_NameEnt[$i][0] & ";"
    If StringInStr($s_S, $s_T, 2) Then
    $o_Dict($s_T) = $a_NameEnt[$i][1]
    EndIf
    Next
    ; Ersetze die Codes durch ihr entsprechendes Zeichen:
    For $i In $o_Dict.Keys
    $s_S = StringReplace($s_S, $i, ChrW($o_Dict($i)))
    Next
    Return $s_S
    EndFunc
    [/autoit]

  • Stringregex Problem bei Livescore.com

    • kra88
    • 9. Januar 2012 um 11:38

    so hier mal ein bissl mehr vom Quellcode

    [autoit]


    #include <Array.au3>
    InetGet("http://livescore.com/soccer/live/", @ScriptDir & "\daten\test.txt")
    $file = fileopen(@ScriptDir & "\daten\test.txt",0)
    If $file = -1 Then
    MsgBox(0, "Error", "Unable to open file.")
    Else

    [/autoit][autoit][/autoit][autoit]

    EndIf
    $test = FileRead($file)
    ;$ergebnisnew_= StringRegExp($test,'border="0">([^<]+)</td><t\D+[^>]+>([^<]+)</td><t[^>]+>[^>]+>([^<]+)\D+[^>]+>([^<]+)',3)
    $ergebnisnew= StringRegExp($test,'border=.\d.>.(\d+)\D+\d+\D+\d+\D+([^<]+)\D+[^>]+>([^<]+)',3)
    ;_ArrayDisplay($ergebnisnew_,"Mehr")
    _ArrayDisplay($ergebnisnew,"weniger")

    [/autoit]

    das problem ist aktuell sind keine spiele vorhanden. Der Quellcode von der seite sieht aber leider auch so nicht besser aus...
    ich hab nochmal das testfile mitangehängt

    Dateien

    test_.txt 51,37 kB – 501 Downloads
  • Stringregex Problem bei Livescore.com

    • kra88
    • 9. Januar 2012 um 11:17

    Hallo Leute ich habe folgendes Problem;

    In dem Folgenden Quellcode sind 11 Fußballspiele. Ich möchte alle Fußballspiele mit Zeit,Mannschaft1,Spielstand, Manschhaft 2. auslesen. ich schaffe leider nur 8 von 11 auszulesen. kann mir einer helfen, damit ich alle 11 Spiele auslesen kann.

    hier der quellcode:

    Spoiler anzeigen
    Code
    <td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i37" alt=""><a href="/soccer/czechia/" onmouseover="i37.src=on.src" onmouseout="i37.src=off.src"> Czech Republic</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i38" alt=""><a href="/soccer/estonia/" onmouseover="i38.src=on.src" onmouseout="i38.src=off.src"> Estonia</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i39" alt=""><a href="/soccer/hungary/" onmouseover="i39.src=on.src" onmouseout="i39.src=off.src"> Hungary</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i40" alt=""><a href="/soccer/israel/" onmouseover="i40.src=on.src" onmouseout="i40.src=off.src"> Israel</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i41" alt=""><a href="/soccer/latvia/" onmouseover="i41.src=on.src" onmouseout="i41.src=off.src"> Latvia</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i42" alt=""><a href="/soccer/lithuania/" onmouseover="i42.src=on.src" onmouseout="i42.src=off.src"> Lithuania</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i43" alt=""><a href="/soccer/moldova/" onmouseover="i43.src=on.src" onmouseout="i43.src=off.src"> Moldova</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i44" alt=""><a href="/soccer/montenegro/" onmouseover="i44.src=on.src" onmouseout="i44.src=off.src"> Montenegro</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i45" alt=""><a href="/soccer/poland/" onmouseover="i45.src=on.src" onmouseout="i45.src=off.src"> Poland</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i46" alt=""><a href="/soccer/romania/" onmouseover="i46.src=on.src" onmouseout="i46.src=off.src"> Romania</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i47" alt=""><a href="/soccer/russia/" onmouseover="i47.src=on.src" onmouseout="i47.src=off.src"> Russia</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i48" alt=""><a href="/soccer/serbia/" onmouseover="i48.src=on.src" onmouseout="i48.src=off.src"> Serbia</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i49" alt=""><a href="/soccer/slovakia/" onmouseover="i49.src=on.src" onmouseout="i49.src=off.src"> Slovakia</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i50" alt=""><a href="/soccer/slovenia/" onmouseover="i50.src=on.src" onmouseout="i50.src=off.src"> Slovenia</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i51" alt=""><a href="/soccer/ukraine/" onmouseover="i51.src=on.src" onmouseout="i51.src=off.src"> Ukraine</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="4"></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i53" alt=""><a href="/soccer/southamerica/" onmouseover="i53.src=on.src" onmouseout="i53.src=off.src"> South America</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i54" alt=""><a href="/soccer/copaamerica/" onmouseover="i54.src=on.src" onmouseout="i54.src=off.src"> Copa America</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i55" alt=""><a href="/soccer/argentina/" onmouseover="i55.src=on.src" onmouseout="i55.src=off.src"> Argentina</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i56" alt=""><a href="/soccer/bolivia/" onmouseover="i56.src=on.src" onmouseout="i56.src=off.src"> Bolivia</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i57" alt=""><a href="/soccer/brazil/" onmouseover="i57.src=on.src" onmouseout="i57.src=off.src"> Brazil</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i58" alt=""><a href="/soccer/chile/" onmouseover="i58.src=on.src" onmouseout="i58.src=off.src"> Chile</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i59" alt=""><a href="/soccer/colombia/" onmouseover="i59.src=on.src" onmouseout="i59.src=off.src"> Colombia</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i60" alt=""><a href="/soccer/ecuador/" onmouseover="i60.src=on.src" onmouseout="i60.src=off.src"> Ecuador</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i61" alt=""><a href="/soccer/paraguay/" onmouseover="i61.src=on.src" onmouseout="i61.src=off.src"> Paraguay</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i62" alt=""><a href="/soccer/peru/" onmouseover="i62.src=on.src" onmouseout="i62.src=off.src"> Peru</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i63" alt=""><a href="/soccer/uruguay/" onmouseover="i63.src=on.src" onmouseout="i63.src=off.src"> Uruguay</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i64" alt=""><a href="/soccer/venezuela/" onmouseover="i64.src=on.src" onmouseout="i64.src=off.src"> Venezuela</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="4"></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i66" alt=""><a href="/soccer/concacaf/" onmouseover="i66.src=on.src" onmouseout="i66.src=off.src"> CONCACAF</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i67" alt=""><a href="/soccer/mexico/" onmouseover="i67.src=on.src" onmouseout="i67.src=off.src"> Mexico</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i68" alt=""><a href="/soccer/usa/" onmouseover="i68.src=on.src" onmouseout="i68.src=off.src"> USA (MLS)</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i69" alt=""><a href="/soccer/costarica/" onmouseover="i69.src=on.src" onmouseout="i69.src=off.src"> Costa Rica</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i70" alt=""><a href="/soccer/elsalvador/" onmouseover="i70.src=on.src" onmouseout="i70.src=off.src"> El Salvador</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i71" alt=""><a href="/soccer/guatemala/" onmouseover="i71.src=on.src" onmouseout="i71.src=off.src"> Guatemala</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i72" alt=""><a href="/soccer/honduras/" onmouseover="i72.src=on.src" onmouseout="i72.src=off.src"> Honduras</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="4"></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" </a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i82" alt=""><a href="/soccer/armenia/" onmouseover="i82.src=on.src" onmouseout="i82.src=off.src"> Armenia</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i83" alt=""><a href="/soccer/azerbaijan/" onmouseover="i83.src=on.src" onmouseout="i83.src=off.src"> Azerbaijan</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i84" alt=""><a href="/soccer/georgia/" onmouseover="i84.src=on.src" onmouseout="i84.src=off.src"> Georgia</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i85" alt=""><a href="/soccer/kazakhstan/" onmouseover="i85.src=on.src" onmouseout="i85.src=off.src"> Kazakhstan</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i86" alt=""><a href="/soccer/kuwait/" onmouseover="i86.src=on.src" onmouseout="i86.src=off.src"> Kuwait</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i87" alt=""><a href="/soccer/iran/" onmouseover="i87.src=on.src" onmouseout="i87.src=off.src"> Iran</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="4"></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i89" alt=""><a href="/soccer/oceania/" onmouseover="i89.src=on.src" onmouseout="i89.src=off.src"> Oceania</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i90" alt=""><a href="/soccer/australia/" onmouseover="i90.src=on.src" onmouseout="i90.src=off.src"> Australia</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="4"></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i92" alt=""><a href="/soccer/africa/" onmouseover="i92.src=on.src" onmouseout="i92.src=off.src"> Africa</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i93" alt=""><a href="/soccer/algeria/" onmouseover="i93.src=on.src" onmouseout="i93.src=off.src"> Algeria</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i94" alt=""><a href="/soccer/egypt/" onmouseover="i94.src=on.src" onmouseout="i94.src=off.src"> Egypt</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i95" alt=""><a href="/soccer/morocco/" onmouseover="i95.src=on.src" onmouseout="i95.src=off.src"> Morocco</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i96" alt=""><a href="/soccer/southafrica/" onmouseover="i96.src=on.src" onmouseout="i96.src=off.src"> South Africa</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i97" alt=""><a href="/soccer/tunisia/" onmouseover="i97.src=on.src" onmouseout="i97.src=off.src"> Tunisia</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="2"></td></tr></table></td><td width="1" bgcolor="#222222"></td><td width="1" bgcolor="#666666"></td><td width="4"></td><td width="468" valign="top" bgcolor="#111111"><table width="468" bgcolor="#666666" cellspacing="0" cellpadding="0" border="0"><tr bgcolor="#111111"><td colspan="4" height="4"></td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#333333"><td class="title" colspan="4" height="18">&nbsp;<b>International</b> - Club Friendlies</td></tr><tr bgcolor="#cfcfcf"><td width="45" height="18">&nbsp;<img src="http://cdn3.livescore.com/img/flash.gif" width="8" height="8" border="0"> 77'</td><td align="right" width="186">Kaiserslautern</td><td align="center" width="51"><a class="scorelink" target="match_details" onclick="window.open('','match_details','width=400,height=171,menubar=no,status=no,location=no,toolbar=no,scrollbars=no,resizable=yes')" href="/default.dll/game?comp=friendly&game=579269">1 - 5</a></td><td width="186">AA Gent</td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#dfdfdf"><td width="45" height="18">&nbsp;<img src="http://cdn3.livescore.com/img/flash.gif" width="8" height="8" border="0"> 15'</td><td align="right" width="186">Club Brugge</td><td align="center" width="51">0 - 0</td><td width="186">Hamburger SV</td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#111111"><td colspan="4" height="4"></td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#333333"><td class="title" colspan="4" height="18">&nbsp;<b>England</b> - FA Cup</td></tr><tr bgcolor="#dfdfdf"><td width="45" height="18">&nbsp;<img src="http://cdn3.livescore.com/img/flash.gif" width="8" height="8" border="0"> 87'</td><td align="right" width="186">Peterborough U.</td><td align="center" width="51"><a class="scorelink" target="match_details" onclick="window.open('','match_details','width=400,height=86,menubar=no,status=no,location=no,toolbar=no,scrollbars=no,resizable=yes')" href="/default.dll/game?comp=england_fa_cup&game=570964">0 - 2</a></td><td width="186">Sunderland</td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#111111"><td colspan="4" height="4"></td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#333333"><td class="title" colspan="4" height="18">&nbsp;<b>Spain</b> - Primera Division</td></tr><tr bgcolor="#cfcfcf"><td width="45" height="18">&nbsp;<img src="http://cdn3.livescore.com/img/flash.gif" width="8" height="8" border="0"> 15'</td><td align="right" width="186">Villarreal</td><td align="center" width="51"><a class="scorelink" target="match_details" onclick="window.open('','match_details','width=400,height=69,menubar=no,status=no,location=no,toolbar=no,scrollbars=no,resizable=yes')" href="/default.dll/game?comp=spain1&game=528122">1 - 0</a></td><td width="186">Valencia</td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#111111"><td colspan="4" height="4"></td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#333333"><td class="title" colspan="4" height="18">&nbsp;<b>Portugal</b> - Liga Sagres</td></tr><tr bgcolor="#cfcfcf"><td width="45" height="18">&nbsp;<img src="http://cdn3.livescore.com/img/flash.gif" width="8" height="8" border="0"> 57'</td><td align="right" width="186">Gil Vicente</td><td align="center" width="51"><a class="scorelink" target="match_details" onclick="window.open('','match_details','width=400,height=103,menubar=no,status=no,location=no,toolbar=no,scrollbars=no,resizable=yes')" href="/default.dll/game?comp=portugal1&game=521123">0 - 2</a></td><td width="186">Nacional</td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#dfdfdf"><td width="45" height="18">&nbsp;<img src="http://cdn3.livescore.com/img/flash.gif" width="8" height="8" border="0"> 57'</td><td align="right" width="186">Maritimo</td><td align="center" width="51"><a class="scorelink" target="match_details" onclick="window.open('','match_details','width=400,height=120,menubar=no,status=no,location=no,toolbar=no,scrollbars=no,resizable=yes')" href="/default.dll/game?comp=portugal1&game=521125">2 - 1</a></td><td width="186">Olhanense</td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#cfcfcf"><td width="45" height="18">&nbsp;<img src="http://cdn3.livescore.com/img/flash.gif" width="8" height="8" border="0"> 57'</td><td align="right" width="186">Rio Ave</td><td align="center" width="51"><a class="scorelink" target="match_details" onclick="window.open('','match_details','width=400,height=86,menubar=no,status=no,location=no,toolbar=no,scrollbars=no,resizable=yes')" href="/default.dll/game?comp=portugal1&game=521126">1 - 0</a></td><td width="186">Pacos Ferreira</td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#111111"><td colspan="4" height="4"></td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#333333"><td class="title" colspan="4" height="18">&nbsp;<b>Portugal</b> - Liga Vitalis</td></tr><tr bgcolor="#dfdfdf"><td width="45" height="18">&nbsp;<img src="http://cdn3.livescore.com/img/flash.gif" width="8" height="8" border="0"> 57'</td><td align="right" width="186">Associacao Naval</td><td align="center" width="51">0 - 0</td><td width="186">Arouca</td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#cfcfcf"><td width="45" height="18">&nbsp;<img src="http://cdn3.livescore.com/img/flash.gif" width="8" height="8" border="0"> 57'</td><td align="right" width="186">Moreirense</td><td align="center" width="51"><a class="scorelink" target="match_details" onclick="window.open('','match_details','width=400,height=86,menubar=no,status=no,location=no,toolbar=no,scrollbars=no,resizable=yes')" href="/default.dll/game?comp=portugal2&game=522170">2 - 0</a></td><td width="186">Santa Clara</td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#111111"><td colspan="4" height="4"></td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#333333"><td class="title" colspan="4" height="18">&nbsp;<b>Turkey</b> - Super Lig</td></tr><tr bgcolor="#cfcfcf"><td width="45" height="18">&nbsp;<img src="http://cdn3.livescore.com/img/flash.gif" width="8" height="8" border="0"> 15'</td><td align="right" width="186">Ankaragucu</td><td align="center" width="51">0 - 0</td><td width="186">Besiktas</td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#111111"><td colspan="4" height="4"></td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#333333"><td class="title" colspan="4" height="18">&nbsp;<b>Cyprus</b> - 1. Division</td></tr><tr bgcolor="#dfdfdf"><td width="45" height="18">&nbsp;<img src="http://cdn3.livescore.com/img/flash.gif" width="8" height="8" border="0"> 57'</td><td align="right" width="186">Alki</td><td align="center" width="51"><a class="scorelink" target="match_details" onclick="window.open('','match_details','width=400,height=86,menubar=no,status=no,location=no,toolbar=no,scrollbars=no,resizable=yes')" href="/default.dll/game?comp=cyprus1&game=529853">1 - 1</a></td><td width="186">APOEL Nicosia</td></tr><tr><td colspan="4" height="1"></td></tr><tr bgcolor="#111111"><td colspan="4" height="4"></td></tr></table></td><td width="4" bgcolor="#111111"></td><td width="144" bgcolor="#111111" valign="top"><table cellspacing="0" cellpadding="0" border="0"><tr><td height="4"></td></tr><tr><td align="center" bgcolor="#333333"><iframe allowtransparency='true' src='http://imstore.bet365affiliates.com/365_047633-417-151-2-149-1-3384.aspx' width='140' height='200' scrolling='no' frameborder='0' style='border-width:0'></iframe></td></tr><tr><td height="4"></td></tr><tr><td width="140" valign="top" bgcolor="#444444"><table bgcolor="#444444" cellspacing="0" cellpadding="0" border="0" width="140"><tr><td height="2"></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i82" alt=""><a href="/" class="menulink" onmouseover="i82.src=on.src" onmouseout="i82.src=off.src"> Home</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/sel.gif" width="13" height="12" hspace="3" name="i83" alt=""><a href="/soccer/live/" class="selected"> All Live</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i84" alt=""><a href="/soccer/soccer/" class="menulink" onmouseover="i84.src=on.src" onmouseout="i84.src=off.src"> All Soccer</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="18"><img src="http://cdn3.livescore.com/img/off.gif" width="13" height="12" hspace="3" name="i85" alt=""><a href="/soccer/contact/" class="menulink" onmouseover="i85.src=on.src" onmouseout="i85.src=off.src"> Contact Us</a></td></tr><tr bgcolor="#222222"><td height="1"></td></tr><tr bgcolor="#777777"><td height="1"></td></tr><tr><td height="2"></td></tr></table></td></tr><tr><td height="4"></td></tr><tr><td align="center" bgcolor="#333333"><iframe src="http://serve.williamhill.com/promoLoadDisplay?member=livescore2&campaign=DEFAULT&channel=DEFAULT&zone=1473406745&lp=0" style="height:200px;width:140px;" frameborder="0" scrolling="no" MARGINWIDTH="0" MARGINHEIGHT="0"></iframe></td></tr><tr><td height="4"></td></tr></table></td></tr></table></td></tr><tr><td><table border="0" cellpadding="0" cellspacing="0"><tr bgcolor="#111111"><td class="copyright" height="20" width="375">&nbsp;Soccer live scores by LiveScore.com</td><td class="copyright" width="375" align="right">© 1998-2012 LiveScore Ltd.&nbsp;</td></tr></table></td></tr></table><script src="http://www.google-analytics.com/urchin.js" type="text/javascript"></script><script type="text/javascript">_uacct = "UA-426278-1";urchinTracker();</script>

    Hier mein Autoitcode:

    http://www.autoitscript.com/autoit3/docs/i…g_variables.htm

    [autoit]


    $aresult8 = StringRegExp($test,'border="0">([^<]+)</td><t\D+[^>]+>([^<]+)</td><t[^>]+>[^>]+>([^<]+)\D+[^>]+>([^<]+)',3)
    $aresult3= StringRegExp($test,'border="0">([^<]+)</td><t\D+[^>]+>([^<]+)</td><t[^>]+>([^<]+)</td><td[^>]+>([^<]+)',3)

    [/autoit]

    //edit

    ich hab es geschaft. danke an alle für die Hilfe

  • Im Quelltext mit WinHttp gezielte Sachen rausfiltern

    • kra88
    • 19. Dezember 2011 um 09:33

    versuch es einfach mal so:

    [autoit]


    #include <WinHttp.au3>
    #include <array.au3>

    [/autoit][autoit][/autoit][autoit][/autoit][autoit]

    $url="euw.leagueoflegends.com"
    $folder = "/de/items"
    $file = @ScriptDir & "\quelltext.html"

    [/autoit][autoit][/autoit][autoit][/autoit][autoit]

    $hsession = _winhttpopen("Mozilla/5.0 (Windows NT 6.1; rv:8.0) Gecko/20100101 Firefox/8.0")
    $hconnect = _winhttpconnect($hsession, $url)
    $shtml = _winhttpsimplerequest($hconnect, "GET", $folder)

    [/autoit][autoit][/autoit][autoit]

    $aitemname= StringRegExp($shtml,'champion_name">([^<]+)',3)
    $aitemid= StringRegExp($shtml,'item/([^<.]+).png',3)
    _ArrayDisplay($aitemname,"Itemname")
    _ArrayDisplay($aitemid,"Itemid")

    [/autoit][autoit][/autoit][autoit]

    FileWrite($file, $shtml)

    [/autoit]
  • [Beispiel] Slide GUI

    • kra88
    • 9. November 2011 um 11:19

    Hallo Leute habe gerade durch zufall den Thread durch google gefunden. Jetzt wollte ich das mit meiner Gui einbinden,

    aber leider kommt folgende Fehlermeldung:

    Code
    >"D:\Daten\Potable\SciTE4AutoIt3\AutoIt3Wrapper\AutoIt3Wrapper.exe" /run /prod /ErrorStdOut /in "D:\Daten\Potable\Autoit\scripte\Autologin\Autologin_slide.au3" /autoit3dir "C:\Program Files (x86)\AutoIt3" /UserParams    
    +>10:29:29 Starting AutoIt3Wrapper v.2.0.3.0	Environment(Language:0407  Keyboard:00000407  OS:WIN_XP/Service Pack 3  CPU:X64 OS:X86)
    >Running AU3Check (1.54.19.0)  from:C:\Programme\AutoIt3
    +>10:29:29 AU3Check ended.rc:0
    >Running:(3.3.6.1):C:\Programme\AutoIt3\autoit3.exe "D:\Daten\Potable\Autoit\scripte\Autologin\Autologin_slide.au3"    
    D:\Daten\Potable\Autoit\scripte\Autologin\Autologin_slide.au3 (157) : ==> Subscript used with non-Array variable.:
    WinMove($hWnd, "", 0 - (($h = -1) * ($m = -1) * ($aWPos[2] - 10)) + (($h = 1) * (($h = 1) * @DesktopWidth - (10 * ($m = -1)) - ($m <> -1) * $aWPos[2])) + (($h = 0) * (($h = 0) * (@DesktopWidth / 2) - ($aWPos[2] / 2))) , 0 - (($v = -1) * ($m = -1) * ($aWPos[3] - 10)) + (($v = 1) * (($v = 1) * @DesktopHeight - (10 * ($m = -1)) - ($m <> -1) * $aWPos[3])) + (($v = 0) * (($v = 0) * (@DesktopHeight / 2) - ($aWPos[3] / 2))) )
    WinMove($hWnd, "", 0 - (($h = -1) * ($m = -1) * ($aWPos^ ERROR
    ->10:29:30 AutoIT3.exe ended.rc:1
    >Exit code: 1	Time: 1.810

    mit dem Beispiel funktioniert es. könnt ihr mir weiterhelfen?

    hier noch mein Code.

    Spoiler anzeigen
    [autoit]


    #include <Array.au3>
    #include <WindowsConstants.au3>
    #include <ButtonConstants.au3>
    #include <GUIConstantsEx.au3>
    #include <WindowsConstants.au3>
    #include <ListViewConstants.au3>
    #Include <GuiListView.au3>

    [/autoit] [autoit][/autoit] [autoit]

    HotKeySet("{ESC}", "_Exit") ; Set the Hotkey to exit.
    $hDLL = DllOpen("user32.dll") ; Open the DLL for _WinIsHovered() (faster with DLL-handle)

    [/autoit] [autoit][/autoit] [autoit]

    Global $h_Left,$h_Bottom,$h_Right,$h_Top

    [/autoit] [autoit][/autoit] [autoit]

    ;funktion für erstellen für die einzelnen Menüs

    [/autoit] [autoit][/autoit] [autoit]

    _menu_links()
    _menu_rechts()
    _menu_oben()
    ;_menu_unten()

    [/autoit] [autoit][/autoit] [autoit][/autoit] [autoit][/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]

    ; Move GUI's to the right place and set the Variables State to False
    Global $LEFT_IN = False, $RIGHT_IN = False, $BOTTOM_IN = False, $TOP_IN = False
    _SlideWin($h_Left, "out", "left")
    _SlideWin($h_Right, "out", "right")
    _SlideWin($h_Bottom, "out", "bottom")
    _SlideWin($h_Top, "out", "top")

    [/autoit] [autoit][/autoit] [autoit]

    ; Show GUI's
    GUISetState(@SW_SHOWNOACTIVATE, $h_Left)
    GUISetState(@SW_SHOWNOACTIVATE, $h_Right)
    ;GUISetState(@SW_SHOWNOACTIVATE, $h_Bottom)
    GUISetState(@SW_SHOWNOACTIVATE, $h_Top)

    [/autoit] [autoit][/autoit] [autoit]

    While 1 * Sleep(10)
    $nMsg = GUIGetMsg(1)
    Select
    Case $nMsg[0] = -3
    Exit
    Case _WinIsHovered($h_Left, $hDLL) ; Check if we need to Slide in a GUI.
    If Not $LEFT_IN Then ; If not already slide-in,
    _SlideWin($h_Left, "in", "left") ; Slide in GUI
    $LEFT_IN = True ; Set var to True.
    EndIf
    Case _WinIsHovered($h_Right, $hDLL)
    If Not $RIGHT_IN Then
    _SlideWin($h_Right, "in", "right")
    $RIGHT_IN = True
    EndIf
    Case _WinIsHovered($h_Bottom, $hDLL)
    If Not $BOTTOM_IN Then
    _SlideWin($h_Bottom, "in", "bottom")
    $BOTTOM_IN = True
    EndIf
    Case _WinIsHovered($h_Top, $hDLL)
    If Not $TOP_IN Then
    _SlideWin($h_Top, "in", "top")
    $TOP_IN = True
    EndIf
    Case Else ; No window is hovered. Check if we need to Slide out a GUI.
    Select
    Case $LEFT_IN
    _SlideWin($h_Left, "out", "left")
    $LEFT_IN = False
    Case $RIGHT_IN
    _SlideWin($h_Right, "out", "right")
    $RIGHT_IN = False
    Case $TOP_IN
    _SlideWin($h_Top, "out", "top")
    $TOP_IN = False
    Case $BOTTOM_IN
    _SlideWin($h_Bottom, "out", "bottom")
    $BOTTOM_IN = False
    EndSelect
    EndSelect
    WEnd

    [/autoit] [autoit][/autoit] [autoit]

    Func _menu_links()
    $h_Left = GUICreate("Login", 307, 249, 320, 186)
    $mi_datei = GUICtrlCreateMenu("Datei")
    $mi_save = GUICtrlCreateMenuItem("Speichern", $mi_datei)
    $mi_einst = GUICtrlCreateMenuItem("Einstellungen", $mi_datei)
    $mi_exit = GUICtrlCreateMenuItem("Beenden", $mi_datei)
    $bt_myhr = GUICtrlCreateButton("MyHr / ESS", 48, 176, 65, 25)
    $bt_leman = GUICtrlCreateButton("Leman", 192, 176, 65, 25)
    $bt_mega = GUICtrlCreateButton("Megaplan", 48, 200, 65, 25)
    $bt_wmsti = GUICtrlCreateButton("WMSTI", 120, 176, 65, 25)
    $bt_orka = GUICtrlCreateButton("ORKA", 192, 200, 65, 25)
    $bt_sap = GUICtrlCreateButton("SAP", 120, 200, 65, 25)
    $h_Left = GUICtrlCreateListView("Programm|Usernmae|Passwort", 8, 8, 289, 161, -1, BitOR($WS_EX_CLIENTEDGE,$LVS_EX_GRIDLINES))
    GUICtrlSetBkColor(-1, 0xFFFAFA)
    GUICtrlSetBkColor($h_Left,$GUI_BKCOLOR_LV_ALTERNATE)
    EndFunc

    [/autoit] [autoit][/autoit] [autoit]

    func _menu_rechts()
    $h_Right = GUICreate("Login", 307, 249, 320, 186)
    $mi_datei = GUICtrlCreateMenu("Datei")
    $mi_save = GUICtrlCreateMenuItem("Speichern", $mi_datei)
    $mi_einst = GUICtrlCreateMenuItem("Einstellungen", $mi_datei)
    $mi_exit = GUICtrlCreateMenuItem("Beenden", $mi_datei)
    $bt_myhr = GUICtrlCreateButton("MyHr / ESS", 48, 176, 65, 25)
    $bt_leman = GUICtrlCreateButton("Leman", 192, 176, 65, 25)
    $bt_mega = GUICtrlCreateButton("Megaplan", 48, 200, 65, 25)
    $bt_wmsti = GUICtrlCreateButton("WMSTI", 120, 176, 65, 25)
    $bt_orka = GUICtrlCreateButton("ORKA", 192, 200, 65, 25)
    $bt_sap = GUICtrlCreateButton("SAP", 120, 200, 65, 25)
    $h_Right= GUICtrlCreateListView("Programm|Usernmae|Passwort", 8, 8, 289, 161, -1, BitOR($WS_EX_CLIENTEDGE,$LVS_EX_GRIDLINES))
    GUICtrlSetBkColor(-1, 0xFFFAFA)
    GUICtrlSetBkColor($h_Right,$GUI_BKCOLOR_LV_ALTERNATE)
    endfunc

    [/autoit] [autoit][/autoit] [autoit]

    func _menu_oben()
    $h_Bottom = GUICreate("Login", 307, 249, 320, 186)
    $mi_datei = GUICtrlCreateMenu("Datei")
    $mi_save = GUICtrlCreateMenuItem("Speichern", $mi_datei)
    $mi_einst = GUICtrlCreateMenuItem("Einstellungen", $mi_datei)
    $mi_exit = GUICtrlCreateMenuItem("Beenden", $mi_datei)
    $bt_myhr = GUICtrlCreateButton("MyHr / ESS", 48, 176, 65, 25)
    $bt_leman = GUICtrlCreateButton("Leman", 192, 176, 65, 25)
    $bt_mega = GUICtrlCreateButton("Megaplan", 48, 200, 65, 25)
    $bt_wmsti = GUICtrlCreateButton("WMSTI", 120, 176, 65, 25)
    $bt_orka = GUICtrlCreateButton("ORKA", 192, 200, 65, 25)
    $bt_sap = GUICtrlCreateButton("SAP", 120, 200, 65, 25)
    $h_Bottom = GUICtrlCreateListView("Programm|Usernmae|Passwort", 8, 8, 289, 161, -1, BitOR($WS_EX_CLIENTEDGE,$LVS_EX_GRIDLINES))
    GUICtrlSetBkColor(-1, 0xFFFAFA)
    GUICtrlSetBkColor($h_Bottom,$GUI_BKCOLOR_LV_ALTERNATE)
    endfunc

    [/autoit] [autoit][/autoit] [autoit]

    func _menu_unten()
    $h_Top = GUICreate("Login", 307, 249, 320, 186)
    $mi_datei = GUICtrlCreateMenu("Datei")
    $mi_save = GUICtrlCreateMenuItem("Speichern", $mi_datei)
    $mi_einst = GUICtrlCreateMenuItem("Einstellungen", $mi_datei)
    $mi_exit = GUICtrlCreateMenuItem("Beenden", $mi_datei)
    $bt_myhr = GUICtrlCreateButton("MyHr / ESS", 48, 176, 65, 25)
    $bt_leman = GUICtrlCreateButton("Leman", 192, 176, 65, 25)
    $bt_mega = GUICtrlCreateButton("Megaplan", 48, 200, 65, 25)
    $bt_wmsti = GUICtrlCreateButton("WMSTI", 120, 176, 65, 25)
    $bt_orka = GUICtrlCreateButton("ORKA", 192, 200, 65, 25)
    $bt_sap = GUICtrlCreateButton("SAP", 120, 200, 65, 25)
    $h_Bottom = GUICtrlCreateListView("Programm|Usernmae|Passwort", 8, 8, 289, 161, -1, BitOR($WS_EX_CLIENTEDGE,$LVS_EX_GRIDLINES))
    GUICtrlSetBkColor(-1, 0xFFFAFA)
    GUICtrlSetBkColor($h_Bottom,$GUI_BKCOLOR_LV_ALTERNATE)
    EndFunc

    [/autoit] [autoit][/autoit] [autoit][/autoit] [autoit]

    Func _SlideWin($hWnd, $sMode, $sSide)
    ;$hWnd = Window to slide.
    ;$sMode = Slide-In or -out (in|out)
    ;$sSide = Side where you want the GUI to slide. (left|right|top|bottom)
    Local $aWPos = WinGetPos($hWnd), $m = 0 - ($sMode = "in") + ($sMode = "out")
    Local $h = 0 - ($sSide = "left") + ($sSide = "right"), $v = 0 - ($sSide = "top") + ($sSide = "bottom")

    [/autoit] [autoit][/autoit] [autoit]

    WinMove($hWnd, "", _ ; Move GUI according to $sMode and $sSide.
    0 - (($h = -1) * ($m = -1) * ($aWPos[2] - 10)) _
    + (($h = 1) * (($h = 1) * @DesktopWidth - (10 * ($m = -1)) - ($m <> -1) * $aWPos[2])) _
    + (($h = 0) * (($h = 0) * (@DesktopWidth / 2) - ($aWPos[2] / 2))) _
    , _
    0 - (($v = -1) * ($m = -1) * ($aWPos[3] - 10)) _
    + (($v = 1) * (($v = 1) * @DesktopHeight - (10 * ($m = -1)) - ($m <> -1) * $aWPos[3])) _
    + (($v = 0) * (($v = 0) * (@DesktopHeight / 2) - ($aWPos[3] / 2))) _
    )

    [/autoit] [autoit][/autoit] [autoit]

    $aWPos = WinGetPos($hWnd)
    ; Slide GUI.
    Switch $sSide
    Case "left", "right"
    Local $STEP = (((($h = 1) And ($m = 1)) Or (($h = -1) And ($m = -1))) - ((($h = -1) And ($m = 1)) Or (($h = 1) And ($m = -1)))) * 10
    Local $FROM = $aWPos[0], $TO = $aWPos[0] _
    + (((($h = 1) And ($m = 1)) Or (($h = -1) And ($m = -1))) * ($aWPos[2])) _
    - (((($h = 1) And ($m = -1)) Or (($h = -1) And ($m = 1))) * ($aWPos[2])) - $STEP
    For $i = $aWPos[0] To $TO Step $STEP
    WinMove($hWnd, "", $i, $aWPos[1])
    Sleep(10)
    Next
    Case "top", "bottom"
    Local $STEP = (((($v = 1) And ($m = 1)) Or (($v = -1) And ($m = -1))) - ((($v = -1) And ($m = 1)) Or (($v = 1) And ($m = -1)))) * 10
    Local $FROM = $aWPos[1], $TO = $aWPos[1] _
    + (((($v = 1) And ($m = 1)) Or (($v = -1) And ($m = -1))) * ($aWPos[3])) _
    - (((($v = 1) And ($m = -1)) Or (($v = -1) And ($m = 1))) * ($aWPos[3])) - $STEP
    For $i = $aWPos[1] To $TO Step $STEP
    WinMove($hWnd, "", $aWPos[0], $i)
    Sleep(10)
    Next
    EndSwitch

    [/autoit] [autoit][/autoit] [autoit]

    EndFunc ;==>_SlideWin

    [/autoit] [autoit][/autoit] [autoit]

    Func _WinIsHovered($hWnd, $vDLL = "User32.dll")
    Local $aResult, $aWPos = WinGetPos($hWnd), $aMPos = MouseGetPos()
    Local $tRect = DllStructCreate("int Left;int Top;int Right;int Bottom")
    Local $iLeft = $aWPos[0], $iTop = $aWPos[1], $iWidth = $aWPos[2], $iHeight = $aWPos[3]
    Local $iX = $aMPos[0], $iY = $aMPos[1]
    DllStructSetData($tRect, "Left", $iLeft)
    DllStructSetData($tRect, "Top", $iTop)
    DllStructSetData($tRect, "Right", $iLeft + $iWidth)
    DllStructSetData($tRect, "Bottom", $iTop + $iHeight)

    [/autoit] [autoit][/autoit] [autoit]

    $aResult = DllCall($vDLL, "int", "PtInRect", "ptr", DllStructGetPtr($tRect), "int", $iX, "int", $iY)
    If @error Then Return SetError(@error, 0, False)

    [/autoit] [autoit][/autoit] [autoit]

    Return $aResult[0] <> 0
    EndFunc ;==>_WinIsHovered

    [/autoit] [autoit][/autoit] [autoit]

    Func _Exit()
    DllClose($hDLL) ; Dont forget to close your DLL-Handle
    Exit
    EndFunc ;==>_Exit

    [/autoit]
  • Bestimmten Teil eines HTML Dokuments auslesen

    • kra88
    • 1. November 2011 um 07:08

    die zwei fenster bekommst du weg, indem du das hier auskommentierst oder löscht:

    [autoit]


    ; das hier löschen
    _ArrayDisplay($ergebnis1,"Ergebnis_")
    _ArrayDisplay($ergebnis,"Ergebnis")
    ;oder so
    ;_ArrayDisplay($ergebnis1,"Ergebnis_")
    ;_ArrayDisplay($ergebnis,"Ergebnis")

    [/autoit][autoit][/autoit][autoit][/autoit]

    wenn du die restlichen links postest, dann kann ich das auch für die anderen Seiten machen!

    wenn du es selbst probieren willst, dann schau dir das stringregex Tutorial von Seubo an!

  • Bestimmten Teil eines HTML Dokuments auslesen

    • kra88
    • 30. Oktober 2011 um 20:47
    [autoit]


    #include <IE.au3>
    #include <Array.au3>

    [/autoit][autoit][/autoit][autoit]

    Global $Planet[10]=['Merkur', 'Venus', 'Erde', 'Mars', 'Jupiter', 'Saturn', 'Uranus', 'Neptun', 'Pluto']

    [/autoit][autoit][/autoit][autoit]

    $oIE = _IECreate("http://de.wikipedia.org/wiki/Phobos_(Mond)", 0, 0)
    $sHtml = _IEBodyReadHTML($oIE)
    ClipPut($sHtml)

    [/autoit][autoit][/autoit][autoit]

    $ergebnis1 =StringRegExp($sHtml,'<A.title="([^"]+)',3)
    $ergebnis = StringRegExp($sHtml,'<TD.noWrap>([^<]+)',3)
    _ArrayDisplay($ergebnis1,"Ergebnis_")
    _ArrayDisplay($ergebnis,"Ergebnis")

    [/autoit][autoit][/autoit][autoit]

    FileWriteLine(@ScriptDir&"\ergebnis.txt",$ergebnis1[2])
    For $p= 0 to 7
    $new = ""
    $new = $new&$ergebnis[$p]&@CRLF
    FileWriteLine(@ScriptDir&"\ergebnis.txt",$new)
    next

    [/autoit]
  • RegEx Anzeige-Problem

    • kra88
    • 27. Mai 2011 um 13:22

    @ Ilse

    mit welchem Code haste jetzt dein problem gelöst?

    ich verlinke mal auf das Regex tutorial von seubo; hier

    hier ein auzug aus dem Tutorial:

    Zitat

    Alles was zwischen \Q und \E steht, wird auch genauso gesucht. Die "Funktionen" der Metazeichen werden also nicht aktiv.
    Allerdings ist das normale escapen i.d.R. einfacher, schneller und überischtlicher.

    das ergebnis von:

    [autoit]

    _ArrayDisplay($aArray)

    [/autoit]

    ist:

    Code
    [0]|40
    [1]|Hunde
    [2]|19
    [3]|Katzen
    [4]|43
    [5]|Vögel

    mit der schleife fügt fügt er die Arrayelemnte sozusammen, wie du sie haben wolltest...

    er fängt bei 0 an schreibt zuerst "$" dann "Element $i +1" vom array und das entspricht "Hund" zusätzlcih hängt er er die zahl an von element $i in demfall die 40 an...

    beim next erhöt sich der wert $i um 1... mit dem step 2 springt er dann gleich zur nächsten zahl (19)

    ich hoffe da war verständlich...

    ps: für _arraydisplay ist

    [autoit]

    #include <Array.au3>

    [/autoit]

    notwendig...

  • RegEx Anzeige-Problem

    • kra88
    • 27. Mai 2011 um 05:27

    ich hoffe es ist jetzt so wie du willst:

    [autoit]

    #include <ButtonConstants.au3>
    #include <EditConstants.au3>
    #include <GUIConstantsEx.au3>
    #include <StaticConstants.au3>
    #include <WindowsConstants.au3>
    #Region ### START Koda GUI section ### Form=
    $Form1_1 = GUICreate("Form1", 328, 384, 192, 124)
    $ed_quelle = GUICtrlCreateEdit("", 32, 56, 257, 97)
    GUICtrlSetData(-1, "")
    $lbl_quelle = GUICtrlCreateLabel("Quellcode:", 40, 24, 55, 17)
    $ed_ergebnis = GUICtrlCreateEdit("", 32, 200, 257, 105)
    GUICtrlSetData(-1, "")
    $lbl_erg = GUICtrlCreateLabel("Ergebnis:", 32, 168, 48, 17)
    $bt_start = GUICtrlCreateButton("Start", 32, 344, 97, 25)
    $bt_zwisch = GUICtrlCreateButton("von Zwischenablage in die Box", 104, 24, 161, 17)
    $txt_pfad = GUICtrlCreateInput("test.txt", 32, 312, 257, 21)
    $bt_laden = GUICtrlCreateButton("Lade Datei", 136, 344, 81, 25)
    $bt_oeffnen = GUICtrlCreateButton("Datei öffnen", 224, 344, 65, 25)
    GUISetState(@SW_SHOW)
    #EndRegion ### END Koda GUI section ###

    [/autoit][autoit][/autoit][autoit][/autoit][autoit]

    ;GUICtrlSetData ($ed_quelle,'Hier steht Text<option value="40">Hunde</option>'& @CRLF ,0)
    ;GUICtrlSetData ($ed_quelle,'Hier steht Text<option value="19">Katzen</option>'& @CRLF,0)
    ;GUICtrlSetData ($ed_quelle,'Hier steht Text<option value="43">Vögel</option>Hier steht Text'& @CRLF,0)

    [/autoit][autoit][/autoit][autoit]

    While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
    Case $GUI_EVENT_CLOSE
    Exit
    Case $bt_start
    _start()
    case $bt_zwisch
    _zwischen()
    case $bt_laden
    _laden()
    case $bt_oeffnen
    _dateioeffnen()
    EndSwitch
    WEnd

    [/autoit][autoit][/autoit][autoit][/autoit][autoit]

    func _start()
    $aquelle =GUICtrlRead($ed_quelle)
    $ahunde = StringRegExp($aquelle,'value="([^"]*)">Hunde',3)
    $akatze = StringRegExp($aquelle,'value="([^"]*)">Katzen',3)
    $avoegel = StringRegExp($aquelle,'value="([^"]*)">Vögel',3)
    GUICtrlSetData ($ed_ergebnis,'$Hunde = "'& $ahunde[0]&'"' & @CRLF,0)
    GUICtrlSetData ($ed_ergebnis,'$Katze = "'& $akatze[0]&'"' & @CRLF,0)
    GUICtrlSetData ($ed_ergebnis,'$Vögel = "'& $avoegel[0]&'"' & @CRLF,0)
    EndFunc

    [/autoit][autoit][/autoit][autoit]

    func _zwischen()
    $aquelle= ClipGet()
    GUICtrlSetData ($ed_quelle,"")
    GUICtrlSetData ($ed_quelle,$aquelle,0)
    EndFunc

    [/autoit][autoit][/autoit][autoit]

    func _laden()
    $file = FileRead(GUICtrlRead($txt_pfad))
    GUICtrlSetData($ed_quelle,$file)
    FileClose($file)
    MsgBox(64,"Fertig","Datei eingelesen")
    EndFunc

    [/autoit][autoit][/autoit][autoit]

    func _dateioeffnen()
    $_FILE_OpenDialog = FileOpenDialog("Wähle eine TextDatei aus!", "", "(*.txt)")
    If @error Then
    MsgBox(0, "Error", "Keine Datei ausgewählt!")
    Return 0
    EndIf
    $_FILE_ReadFile = FileRead($_FILE_OpenDialog)
    GUICtrlSetData($ed_quelle, $_FILE_ReadFile)
    EndFunc

    [/autoit]
  • RegEx Anzeige-Problem

    • kra88
    • 26. Mai 2011 um 21:17

    so vielleicht;

    [autoit]

    #include <Array.au3>
    ClipGet()
    $sSource= ClipGet()
    $ahunde = StringRegExp($sSource,'value="([^"]*)">Hunde',3)
    $akatze = StringRegExp($sSource,'value="([^"]*)">Katzen',3)
    $avoegel = StringRegExp($sSource,'value="([^"]*)">Vögel',3)
    $atest = StringRegExp($sSource,'value="([^"]*)',3)
    _arraydisplay($ahunde,"Hunde")
    _arraydisplay($akatze,"katzen")
    _arraydisplay($avoegel,"Vögel")

    [/autoit]

    ansonsten sagen was du genau machen willst...

    was dein ganzen script machen soll bzw. dein projekt

  • RegEx Anzeige-Problem

    • kra88
    • 26. Mai 2011 um 18:46

    versuch es mal so:

    [autoit]

    #include <Array.au3>
    ClipGet()
    $sSource= ClipGet()
    $alinks = StringRegExp($sSource,'value="([^"]*)">([^<]*)',3)
    $atest = StringRegExp($sSource,'value="([^"]*)',3)
    _arraydisplay($alinks,"ergebnis")
    _arraydisplay($atest,"test")

    [/autoit]

    viel spaß damit...

Spenden

Jeder Euro hilft uns, Euch zu helfen.

Download

AutoIt Tutorial
AutoIt Buch
Onlinehilfe
AutoIt Entwickler
  1. Datenschutzerklärung
  2. Impressum
  3. Shoutbox-Archiv
Community-Software: WoltLab Suite™