Exe (Realpopup) läuft nicht

  • Hallo,

    ich habe hier ein Problem. Das Script als au3 läuft - bis ich eine Exe daraus mache. Dann wartet es vergeblich drauf, dass der Prozess verschwindet (Zeile 33). Wo liegt das Problem?

    Spoiler anzeigen
    [autoit]


    IF @OSVersion == "WIN_XP" And @OSLang == "0407" Then

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

    MsgBox(4096, "Firma GmbH", "Auf diesen Rechner wird nun automatisch Realpopup installiert. Die Installation wird etwa 30 Sekunden dauern. Bitte drücken Sie während der Installation keine Tasten. Der Rechner wird nach der Installtion neu gestartet.", 30)
    RunAsSet("User", "Domaene", "PW")
    BlockInput(1)

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

    $DateiName = "Realpopup_" & @ComputerName & ".txt"
    $Fertig = "Realpopup_" & @ComputerName & "_" & @UserName & ".txt"
    $Pfad = "\\Server\LOG\"
    $file1 = FileOpen($Pfad & $DateiName, 10) ; which is similar to 2 + 8 (erase + create dir)

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

    FileCopy("\\Server\Software\Kill.exe", "C:\Install\", 9)
    Run("\\Server\Software\realp26_167.exe")
    WinWaitActive("Setup")
    Send("!j")
    WinWaitActive("Setup - RealPopup")
    Send("!n")
    WinWaitActive("Setup - RealPopup")
    Send("!n")
    WinWaitActive("Setup - RealPopup")
    Send("!n")
    WinWaitActive("Setup - RealPopup")
    Send("!n")
    WinWaitActive("Setup - RealPopup")
    Send("!i")
    Sleep(2000)
    Send("!f")
    Sleep(5000)
    run ("C:\Install\Kill.exe RealPopup.exe")
    ProcessWaitClose("RealPopup.exe")
    Sleep(5000)
    RegWrite("HKEY_CURRENT_USER\Software\Matro")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Advanced")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Advanced", "DisableMessageLengthCheck", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Advanced", "FullInternalPings", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Advanced", "PingTimeOut", "REG_DWORD", "00000064")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Advanced", "DomainSendToRealPopupClientsOnly", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Advanced", "NameResolution", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Advanced", "NameResolutionMinInterval", "REG_DWORD", "000003e8")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Advanced", "RPdatFolder", "REG_SZ", "")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Advanced", "WinpopupSendMailslotEnabled", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Advanced", "WinpopupSendNetbiosEnabled", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Advanced", "WinpopupSendSMBEnabled", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Advanced", "Log", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Advanced", "LogRemote", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Advanced", "LogRemoteIP", "REG_SZ", "")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Advanced", "LogRemotePort", "REG_DWORD", "00001e61")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "ResourceDLL", "REG_SZ", "RPres_ger.dll")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "WelcomeToV2.6", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "BeepOnNewMessage", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "BalloonOnMsgDeliveryIssues", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "AlwaysOnTop", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "MinimizeOnDelLastMessage", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "MinimizeWhenReplied", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "DelOriginalWhenReplied", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "WarnOnExit", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "WarnOnCancelingSend", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "WarnWhenSendToDomain", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "WarnRPProtocolNotActive", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "PlayWav", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "ShowLastMessage", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "AutoStart", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "WindowTop", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "WindowLeft", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "WindowHeight", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "WindowWidth", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "WindowSndTop", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "WindowSndLeft", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "WindowSndHeight", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "WindowSndWidth", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "HotKey", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "HotKeyModifiers", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "HyperlinksDoubleClick", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "LeftButtonTray", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "AwayOnScreenSaver", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "DetermineFavoriteUsers", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "SendAlwaysPcName", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "UseEnterToSendMessage", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "QuoteMessage", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "CaretTopOnReply", "REG_DWORD", "00000000")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "DisableDelKeyForAWhile", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "WavFile", "REG_SZ", "")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "LastDomain", "REG_SZ", "ZIEHM-EU")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "AutoStartWarn", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "AutoStartMsg", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "MessengerService", "REG_DWORD", "00000001")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "MsgSentNum", "REG_DWORD", "0000000b")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "MsgReceivedNum", "REG_DWORD", "00000015")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "FontMessages", "Arial,-11,400,0,0,0,0,1,34")
    RegWrite("HKEY_CURRENT_USER\Software\Matro\RealPopup\Environment", "FontInfos", "Arial,-11,400,0,0,0,0,1,34")
    RegWrite("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run", "RealPopup", "REG_SZ", "C:\Programme\RealPopup\RealPopup.exe BOOT")
    $file1 = FileOpen($Pfad & $Fertig, 10)
    BlockInput(0)
    MsgBox(4096, "Firma GmbH", "Installation beendet. Der Rechner wird jetzt neu gestartet", 20)
    Shutdown(6) ;Force a reboot

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

    ELSE
    Exit
    EndIf

    [/autoit]

    Gruß
    Matthias

    PS Mit der Formatierierung hier komme ich noch nicht so ganz klar. Werde dies aber noch ändern.

    6 Mal editiert, zuletzt von MatthiasNbg (7. August 2007 um 11:11)

  • Hallo Spider,

    mit ProcessClose hatte ich es zu Anfangs probiert. Da bekomme ich den Prozess gar nicht zu.
    Er bleibt ebenso stehen (sogar schon als au3) wie mit "Kill" als Exe... ?(

    Gruß
    Matthias

    Einmal editiert, zuletzt von MatthiasNbg (7. August 2007 um 11:20)

  • Hi,

    man kann das Setup auch direkt silent durchführen. Habe dir mal ne Batch
    zusammen gebaut .. .vielleicht kannst Du ja das ein oder andere gebrauchen.

    Spoiler anzeigen


    @echo off
    REM Schritt eins: erstellen einer Antwortdatei
    REM start realp26_167.exe /SAVEINF="realp.inf"
    REM realp.inf wird im Windowsverzeichnis abgelegt, wenn kein absoluter Pfad angegeben wird
    REM Schritt zwei: automatisierte installation der Anwendung
    echo RealPopup wird installiert ...
    start /wait realp26_167.exe /SP- /LOADINF="realp.inf" /NOCANCEL /SILENT /NORESTART
    REM bei /LOAD="realp.inf" muss der absolute Pfad angegeben werden, wenn sich die Datei nicht im Windowsverzeichnis befindet
    echo RealPopup wird konfiguriert
    REM sofern die konfig.reg vorhanden ist ;)
    start /wait regedit /s konfig.reg
    echo Die Installation ist abgeschlossen


    REM Verfügbare schalter bei einem Innosetup
    REM /SILENT Mit statusanzeige oder /VERYSILENT ohne Statusanzeige

    REM Optionale Schalter
    REM SP- verhindert am Anfang des Setups die Aufforderung zum Beginnen

    REM /NOCANCEL untersagt dem User während des Setups abzubrechen
    REM /NORESTART verhindert Neustart
    REM /SAVEINF="datei.inf" speichert während des Setup's alle Eingaben
    REM /LOADINF="Datei.inf" ruft während des Setups die gespeicherten Informationen
    REM /Dir="Installationspfad"
    REM /COMPONENTS

    Einmal editiert, zuletzt von jonk (7. August 2007 um 12:00)

  • Der Task lässt sich über den Task ohne Fehler killen.
    Das AutoIt Script ignoriert das allerdings. Die Reg. Einträge und der Reboot bleiben aus... AutoIt
    AutoIt scheint hier in einer Schleife zu hängen.
    Wie gesagt, als au3 läuft das ganze fehlerfrei ?(

    Danke für die Batch - mit dem Inf-File mußich mich allerdings erst schlau machen. Allerdings muß ich auch hier erst Realpopup schliessen, bevor ich die Reg-Files rein schreibe. Realpopup speichert seine Einstellungen erst beim schliessen - auch nach der Installation.

    Gruß
    Matthias

  • Die inf-datei erstellst Du ja nur einmal, bevor Du die Software verteilst. Wenn Du die Installation durchführst und beim Aufzeichnen der inf-Datei nicht das Häkchen für "direkt nach installation starten" gesetzt hast, wird die Anwendung nicht gestartet und Du kannst direkt die Werte in die Registry schreiben. Oder muß die Realpopup zwingend einmal gestartet werden?

    EDIT:
    ok... realpopup startet auch nach der silent installation, weil das häkchen nicht in die inf geschrieben wird. Wenn ich allerdings ProcessClose("Realpopup.exe") ausführe wird der Prozess direkt beendet ...

    Einmal editiert, zuletzt von jonk (7. August 2007 um 14:06)