Chat: Nachricht an alle Server schicken ?!?

  • sorry, Begriffsverwechslung.

    ich ging natürlich von einem Funktionsaufruf aus :)

    MfG Schnuffel

    "Sarkasmus ist die niedrigste Form des Witzes, aber die höchste Form der Intelligenz."
    Val McDermid

    über mich...

    ich habe meine Erfahrungen hauptsächlich gesammelt in (grobe Übersicht):

    - RibbonBar Automation
    - MySQL Nutzung
    - GUIs in vielerlei Ausprägung
    - Nutzung von Powershell / Batch in AutoIt
    - Windows Automatisierung

    außerhalb von AutoIt:

    - Sprachen: PS, Batch, php, html(5), javascript, (perl eingeschränkt), vbs
    - Powershell (AD, WPF inkl. Multi-Threading, ...)
    - Deployment-Automatisierung ohne SCCM
    - Office-Nutzung mit COM-Object (AutoIt, PowerShell)
    - ActiveDirectory und alles was damit zusammenhängt
    - Hyper-V Clustering (Converged / Hyper Converged)
    - Serverhardware (Konfiguration, Aufbau, Architektur, Betrieb)

    Lieblingsthema:

    günstige Automatisierung von Vorgängen, für die andere Firmen viel Geld nehmen

    more to come ...

  • server
    [autoit]

    Global $sNamen
    $zahl = -1
    $zahl1 = $zahl + 1
    $File = @ScriptDir & "\Server.ini"
    FileDelete($File)
    #include <EditConstants.au3>
    #include <GUIConstantsEx.au3>
    #include <WindowsConstants.au3>
    Opt("TrayMenuMode",1)
    HotKeySet("{ESC}", "Terminate")
    #Region ### START Koda GUI section ### Form=
    $Form2 = GUICreate("Serververlauf", 500, 201, 303, 219) ;GUICreate ( "title" [, width [, height [, left [, top [, style [, exStyle [, parent]]]]]]] )
    $Edit1 = GUICtrlCreateEdit("", 3, 3, 498, 196, $ES_READONLY+$ES_AUTOHSCROLL) ;GUICtrlCreateEdit ( "text", left, top [, width [, height [, style [, exStyle]]]] )
    GUICtrlSetBkColor(-1, 0xFFFFFF)
    #EndRegion ### END Koda GUI section ###
    $Fenster = False
    Dim $ConnectedSocket[999999]
    Dim $Namen[999999]
    ; Startet den TCP Service
    ;==============================================
    TCPStartup()

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

    ; Erstellt einen lauschenden "SOCKET"
    ;==============================================
    $MainSocket = TCPListen(@IPAddress1, 31758)
    If $MainSocket > -1 Then
    MsgBox (0,"","Die Server-Ip ist: " & @IPAddress1)
    ClipPut(@IPAddress1)
    EndIf
    If $MainSocket = -1 Then
    $MainSocket = TCPListen(@IPAddress2, 31758)
    If $MainSocket > -1 Then
    MsgBox (0,"","Die Server-Ip ist: " & @IPAddress2)
    EndIf
    EndIf
    If $MainSocket = -1 Then
    $MainSocket = TCPListen(@IPAddress3, 31758)
    If $MainSocket > -1 Then
    MsgBox (0,"","Die Server-Ip ist: " & @IPAddress3)
    EndIf
    EndIf
    If $MainSocket = -1 Then
    $MainSocket = TCPListen(@IPAddress4, 31758)
    If $MainSocket > -1 Then
    MsgBox (0,"","Die Server-Ip ist: " & @IPAddress4)
    EndIf
    EndIf
    If $MainSocket = -1 Then MsgBox (16,"Error","Es ist ein Verbindungsfehler aufgetreten!")Exit
    HotKeySet("!{n}", "_Fenster") ; alt + n
    ; Warten auf eine Client-Verbindung
    ;--------------------

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

    While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
    Case $GUI_EVENT_CLOSE
    GUISetState(@SW_HIDE)
    EndSwitch
    $ConnectedSocket[$zahl1] = TCPAccept($MainSocket)
    If $ConnectedSocket[$zahl1] >= 0 Then
    $zahl = $zahl + 1
    $zahl1 = $zahl + 1
    ;~ MsgBox(0, "", "Mein Server - Client verbunden", 1)
    $Erhalten = TCPRecv($ConnectedSocket[$zahl], 2048)
    $sErhalten = StringSplit($Erhalten, ",")
    If $sErhalten[1] = "Name" Then
    $Namen[$zahl] = $sErhalten[2]
    ElseIf $sErhalten[1] = "NamenSenden" Then
    $zahl = $zahl - 1
    For $E = 0 To $sErhalten[2]
    $E1 = $E + 3
    $Namen[$E] = $sErhalten[$E1]
    Next
    $Status = False
    For $F = 0 To $sErhalten[2]
    $F1 = $sErhalten[2] + 1
    $F2 = $F - 1
    If $F = $sErhalten[$F1] Then $Status = True
    If $Status = True Then
    $ConnectedSocket[$F] = $ConnectedSocket[$F2]
    EndIf
    Next
    EndIf
    $sNamen = ""
    For $B = 0 To $zahl
    $sNamen = $sNamen & $Namen[$B] & "|"
    Next
    For $C = 0 To $zahl
    TCPSend($ConnectedSocket[$C], "Namen|" & $zahl & "|" & $sNamen)
    Next
    EndIf
    For $A = 0 To $zahl
    $Erhalten = TCPRecv($ConnectedSocket[$A], 9999)
    $sErhalten = StringSplit($Erhalten, ",")
    If $Erhalten <> "" Then
    $Edit1Read = GUICtrlRead($Edit1)
    GUICtrlSetData($Edit1, $Edit1Read & @CRLF & $Erhalten)
    $Lines = _GUICtrlEdit_GetLineCount($Edit1)
    _GUICtrlEdit_LineScroll($Edit1, 0, $Lines)
    For $D = 0 To $zahl
    If $sErhalten[1] = "Name" Then
    $Namen[$zahl] = $sErhalten[2]
    ElseIf $sErhalten[1] = "Nachricht" Then
    MsgBox (0,"",$Namen[$D] & "," & $sErhalten[3])
    If $Namen[$D] = $sErhalten[3] Then
    TCPSend($ConnectedSocket[$D], $Erhalten)
    EndIf
    EndIf
    Next
    ; wenn meldung gesendet, fenster anzeigen und sound abspielen
    GUISetState(@SW_SHOW)
    #cs
    If Not WinExists("Lautstärkeregelung", "") Then Run('sndvol32', '', @SW_HIDE)
    _SoundSetMasterVolume (75) ; lautstärke nach Einagbe in "einstellung ..." (read ini datei) erhöhen
    _SoundSetWaveVolume (100)
    If @error Then MsgBox("", "118 FEHLER bei Sound", @error)
    $fSpeakersMute = _SoundGet (0, "dSpeakers", 1, "Mute")
    If $fSpeakersMute = 1 Then ; 1= ist mute (still)
    ;MsgBox("","Return",$fSpeakersMute)
    If Not WinExists("Lautstärkeregelung", "") Then Run('sndvol32', '', @SW_HIDE)
    WinActivate("Lautstärkeregelung", "")
    ControlCommand("Lautstärkeregelung", "", 1000, "UnCheck", "") ; mute ausschalten
    EndIf
    #ce
    ;Beep(500, 2000)


    EndIf
    Next
    WEnd

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

    Func Terminate()
    Exit 0
    EndFunc
    Func _Fenster()
    If $Fenster = True Then
    GUISetState(@SW_HIDE)
    ElseIf $Fenster = False Then
    GUISetState(@SW_SHOW)
    EndIf
    EndFunc ;==>_Fenster

    [/autoit]
    • Offizieller Beitrag

    Habe mal die 2 Fehler aus deinem Script getilgt und es en bissle aufgeräumt.Zur Funktion kann ich dir aber nichts sagen , da ich es nicht nachvollziehen kann.

    Spoiler anzeigen
    [autoit]

    #include <EditConstants.au3>
    #include <GUIConstantsEx.au3>
    #include <GuiEdit.au3>
    Opt("TrayMenuMode", 1)

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

    Global $sNamen
    Dim $ConnectedSocket[999999]
    Dim $Namen[999999]
    $Fenster = False
    $zahl = -1
    $zahl1 = $zahl + 1
    $File = @ScriptDir & "\Server.ini"
    FileDelete($File)

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

    HotKeySet("{ESC}", "Terminate")
    HotKeySet("!{n}", "_Fenster") ; alt + n

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

    #Region ### START Koda GUI section ### Form=
    $Form2 = GUICreate("Serververlauf", 500, 201, 303, 219) ;GUICreate ( "title" [, width [, height [, left [, top [, style [, exStyle [, parent]]]]]]] )
    $Edit1 = GUICtrlCreateEdit("", 3, 3, 498, 196, $ES_READONLY + $ES_AUTOHSCROLL) ;GUICtrlCreateEdit ( "text", left, top [, width [, height [, style [, exStyle]]]] )
    GUICtrlSetBkColor(-1, 0xFFFFFF)

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

    #EndRegion ### END Koda GUI section ###

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

    ; Startet den TCP Service
    ;==============================================
    TCPStartup()

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

    ; Erstellt einen lauschenden "SOCKET"
    ;==============================================
    $MainSocket = TCPListen(@IPAddress1, 31758)
    If $MainSocket > -1 Then
    MsgBox(0, "", "Die Server-Ip ist: " & @IPAddress1)
    ClipPut(@IPAddress1)
    EndIf
    If $MainSocket = -1 Then
    $MainSocket = TCPListen(@IPAddress2, 31758)
    If $MainSocket > -1 Then
    MsgBox(0, "", "Die Server-Ip ist: " & @IPAddress2)
    EndIf
    EndIf
    If $MainSocket = -1 Then
    $MainSocket = TCPListen(@IPAddress3, 31758)
    If $MainSocket > -1 Then
    MsgBox(0, "", "Die Server-Ip ist: " & @IPAddress3)
    EndIf
    EndIf
    If $MainSocket = -1 Then
    $MainSocket = TCPListen(@IPAddress4, 31758)
    If $MainSocket > -1 Then
    MsgBox(0, "", "Die Server-Ip ist: " & @IPAddress4)
    EndIf
    EndIf
    If $MainSocket = -1 Then Exit MsgBox(16, "Error", "Es ist ein Verbindungsfehler aufgetreten!")

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

    ; Warten auf eine Client-Verbindung
    ;--------------------

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

    While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
    Case $GUI_EVENT_CLOSE
    GUISetState(@SW_HIDE)
    EndSwitch
    $ConnectedSocket[$zahl1] = TCPAccept($MainSocket)
    If $ConnectedSocket[$zahl1] >= 0 Then
    $zahl = $zahl + 1
    $zahl1 = $zahl + 1
    ;~ MsgBox(0, "", "Mein Server - Client verbunden", 1)
    $Erhalten = TCPRecv($ConnectedSocket[$zahl], 2048)
    $sErhalten = StringSplit($Erhalten, ",")
    If $sErhalten[1] = "Name" Then
    $Namen[$zahl] = $sErhalten[2]
    ElseIf $sErhalten[1] = "NamenSenden" Then
    $zahl = $zahl - 1
    For $E = 0 To $sErhalten[2]
    $E1 = $E + 3
    $Namen[$E] = $sErhalten[$E1]
    Next
    $Status = False
    For $F = 0 To $sErhalten[2]
    $F1 = $sErhalten[2] + 1
    $F2 = $F - 1
    If $F = $sErhalten[$F1] Then $Status = True
    If $Status = True Then
    $ConnectedSocket[$F] = $ConnectedSocket[$F2]
    EndIf
    Next
    EndIf
    $sNamen = ""
    For $B = 0 To $zahl
    $sNamen = $sNamen & $Namen[$B] & "|"
    Next
    For $C = 0 To $zahl
    TCPSend($ConnectedSocket[$C], "Namen|" & $zahl & "|" & $sNamen)
    Next
    EndIf
    For $A = 0 To $zahl
    $Erhalten = TCPRecv($ConnectedSocket[$A], 9999)
    $sErhalten = StringSplit($Erhalten, ",")
    If $Erhalten <> "" Then
    $Edit1Read = GUICtrlRead($Edit1)
    GUICtrlSetData($Edit1, $Edit1Read & @CRLF & $Erhalten)
    $Lines = _GUICtrlEdit_GetLineCount($Edit1)
    _GUICtrlEdit_LineScroll($Edit1, 0, $Lines)
    For $D = 0 To $zahl
    If $sErhalten[1] = "Name" Then
    $Namen[$zahl] = $sErhalten[2]
    ElseIf $sErhalten[1] = "Nachricht" Then
    MsgBox(0, "", $Namen[$D] & "," & $sErhalten[3])
    If $Namen[$D] = $sErhalten[3] Then
    TCPSend($ConnectedSocket[$D], $Erhalten)
    EndIf
    EndIf
    Next
    ; wenn meldung gesendet, fenster anzeigen und sound abspielen
    GUISetState(@SW_SHOW)
    #cs
    If Not WinExists("Lautstärkeregelung", "") Then Run('sndvol32', '', @SW_HIDE)
    _SoundSetMasterVolume (75) ; lautstärke nach Einagbe in "einstellung ..." (read ini datei) erhöhen
    _SoundSetWaveVolume (100)
    If @error Then MsgBox("", "118 FEHLER bei Sound", @error)
    $fSpeakersMute = _SoundGet (0, "dSpeakers", 1, "Mute")
    If $fSpeakersMute = 1 Then ; 1= ist mute (still)
    ;MsgBox("","Return",$fSpeakersMute)
    If Not WinExists("Lautstärkeregelung", "") Then Run('sndvol32', '', @SW_HIDE)
    WinActivate("Lautstärkeregelung", "")
    ControlCommand("Lautstärkeregelung", "", 1000, "UnCheck", "") ; mute ausschalten
    EndIf
    #ce
    ;Beep(500, 2000)

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

    EndIf
    Next
    WEnd

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

    Func Terminate()
    Exit 0
    EndFunc ;==>Terminate
    Func _Fenster()
    If $Fenster = True Then
    GUISetState(@SW_HIDE)
    ElseIf $Fenster = False Then
    GUISetState(@SW_SHOW)
    EndIf
    EndFunc ;==>_Fenster

    [/autoit]
  • sorry hier noch die _pingall

    Spoiler anzeigen
    [autoit]

    #include <GUIConstants.au3>
    #include <array.au3>

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

    ; ##############################################################################
    ; ### PING ALL #################################################################

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

    Func _PingAll($ipstart, $ipend, $iprange = "", $port01 = "", $port02 = "", $port03 = "", $port04 = "", $radim = 0, $winxp = 1, $vnc = 1, $ShowName = 1, $ShowMac = 1, $dealy = 100, $slash = "|", $yes = 1, $no = 0, $showprog = 1, $showbevore = 1)

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

    If $iprange = "" Then
    $iprange = StringSplit(@IPAddress1, ".")
    $iprange = $iprange[1] & "." & $iprange[2] & "." & $iprange[3] & "."
    EndIf
    Local $ipadress[$ipend + 1] = [1, ""]
    $ip = $ipstart
    If $showprog = 1 Then ProgressOn("IP", "IP Check")

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

    Global $ra, $xp, $VNC3, $MAC1, $name1
    If $showbevore = 1 Then
    $ra = "Ra:"
    $xp = "XP:"
    $VNC3 = "VNC:"
    $MAC1 = "Mac:"
    $name1 = "Name:"
    EndIf

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

    $i = 0
    Do
    If $showprog = 1 Then ProgressSet(($ip * 100) / $ipend, $iprange & $ip)
    $ip += 1
    Ping($iprange & $ip, $dealy)
    If Not @error Then
    $i += 1
    $ipadress[$i] &= $iprange & $ip & $slash
    If $port01 <> "" Then $ipadress[$i] &= $port01 & ":" & PortScan($port01, $iprange & $ip, $yes, $no) & $slash
    If $port02 <> "" Then $ipadress[$i] &= $port02 & ":" & PortScan($port02, $iprange & $ip, $yes, $no) & $slash
    If $port03 <> "" Then $ipadress[$i] &= $port03 & ":" & PortScan($port03, $iprange & $ip, $yes, $no) & $slash
    If $port04 <> "" Then $ipadress[$i] &= $port04 & ":" & PortScan($port04, $iprange & $ip, $yes, $no) & $slash
    If $radim <> 0 Then $ipadress[$i] &= $ra & PortScan(4899, $iprange & $ip, $yes, $no) & $slash
    If $winxp <> 0 Then $ipadress[$i] &= $xp & PortScan(3389, $iprange & $ip, $yes, $no) & $slash
    If $vnc <> 0 Then $ipadress[$i] &= $VNC3 & PortScan(5900, $iprange & $ip, $yes, $no) & $slash
    If $ShowMac <> 0 Then $ipadress[$i] &= $MAC1 & _GetMACFromIP($iprange & $ip) & $slash
    If $ShowName <> 0 Then $ipadress[$i] &= $name1 & _IpToName($iprange & $ip) & $slash
    EndIf
    $ipadress[$ip] = StringTrimRight($ipadress[$ip], 1)
    ; MsgBox(0,"ipstart" & $ipstart&" ipend "&$ipend,$iprange&$ip)

    If $showprog = 1 Then ProgressSet(($ip * 100) / $ipend)
    If $showprog <> 0 And $showprog <> 1 Then GUICtrlSetData($showprog, ($ip * 100) / $ipend)
    Until $ip >= $ipend
    $ipadress[0] = $i
    ProgressOff()
    ;_ArrayDisplay($ipadress, "_ArrayDisplay $ipadress")
    Return $ipadress
    EndFunc ;==>_PingAll
    ; ##############################################################################

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

    Func PortScan($port, $ip, $1, $2)
    $socket = TCPConnect($ip, $port)
    If $socket = -1 Then
    Return $2
    Else
    Return $1
    EndIf
    EndFunc ;==>PortScan

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

    Func _GetMACFromIP($sIP)
    Local $MAC, $MACSize
    Local $i, $s, $r, $iIP
    $MAC = DllStructCreate("byte[6]")
    $MACSize = DllStructCreate("int")
    DllStructSetData($MACSize, 1, 6)
    $r = DllCall("Ws2_32.dll", "int", "inet_addr", "str", $sIP)
    $iIP = $r[0]
    $r = DllCall("iphlpapi.dll", "int", "SendARP", "int", $iIP, "int", 0, "ptr", DllStructGetPtr($MAC), "ptr", DllStructGetPtr($MACSize))
    $s = ""
    For $i = 0 To 5
    If $i Then $s = $s & ":"
    $s = $s & Hex(DllStructGetData($MAC, 1, $i + 1), 2)
    Next
    Return $s
    EndFunc ;==>_GetMACFromIP

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

    Func _IpToName($ip)
    $outread = "ERROR: Kann Programm NbtStat.exe nicht finden!"
    Ping($ip, 50)
    If @error Then
    ;~ MsgBox(16,"Ping error","Die adresse "&$ip&" konnte nich gefunden werden, stellen Sie sicher das der Rechner online ist!")
    ;~ Exit
    Return @error
    EndIf
    $run = Run(@ComSpec & " /c nbtstat -a " & $ip, @SystemDir, @SW_HIDE, 6)
    Sleep(500)
    $stdoutread = StdoutRead($run)
    If Not @error = -1 Then $outread = $stdoutread

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

    $stderrRead = StderrRead($run)
    If Not @error = -1 Then $outread = $stderrRead
    $ss = StringSplit($outread, @CRLF)
    If $ss[0] < 23 Then
    $outread = "(Kein Name Vorhanden)"
    Else
    $outread = $ss[23]
    $outread = StringReplace($outread, Chr(129), "ü")
    $outread = StringReplace($outread, Chr(154), "Ü")
    $outread = StringReplace($outread, Chr(142), "Ä")
    $outread = StringReplace($outread, Chr(132), "ä")
    $outread = StringReplace($outread, Chr(153), "Ö")
    $outread = StringReplace($outread, Chr(148), "ö")
    $outreadlen = StringLen("LAN-Verbindung:Knoten-IP-Adresse: [] Bereichskennung: [] NetBIOS-Namentabelle des Remotecomputers Name Typ Status---------------------------------------------") + StringLen($ip)
    $outread = StringTrimLeft($outread, 4)
    $outread = StringSplit($outread, " ")
    $outread = $outread[1]
    $outread = StringReplace($outread, " ", "", 0)
    EndIf
    Return $outread
    EndFunc ;==>_IpToName

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

    ; ##############################################################################
    ; ##############################################################################
    ; ##############################################################################

    [/autoit]

    aber ich glaub das liegt an dem client script, pingall funktioniert > zeigt alle ip's im netz an. dann wird aber glaub ich die zweite for- schleife ubersprungen - zumindest wird keine InputBox geöffnet wies in der _senden funktion steht

    client
    [autoit]

    #include <GUIConstants.au3>
    #include <array.au3>
    #include <_PingAll.au3>
    #include <INet.au3>
    #include <ArrayMore.au3>
    ;$IP = @IPAddress1
    ;MsgBox ("","","Die Server-Ip ist: " & $IP )
    ClipPut(@IPAddress1)
    $aPingAll = _PingAll(20, 50, "", "", "", "", "", 0, 0, 0, 0, 0, 5, " ", "1", "0", 0, 0)
    ;_PingAll($ipstart, $ipend, $iprange = "", $port01 = "", $port02 = "", $port03 = "", $port04 = "",
    ;$radim = 0, $winxp = 1, $vnc = 1, $ShowName = 1, $ShowMac = 1, $dealy = 100, $slash = "|", $yes = 1, $no = 0, $showprog = 1, $showbevore = 1)
    _Array2DEmptyDel($aPingAll, 0) ;_Array2DEmptyDel(ByRef $avArray [, $Col=0])
    _ArrayDelete($aPingAll, 0); Erstes Element aus dem Array löschen
    $sUbound = (UBound($aPingAll) - 1)
    If $aPingAll[$sUbound] = "" Then _ArrayDelete($aPingAll, ($sUbound))
    _ArrayDisplay($aPingAll, "ipadress gesamt")

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

    For $x = 0 To UBound($aPingAll) - 1 ;
    $IP = $aPingAll[$x]
    MsgBox("", "$IP", $IP)
    Next
    For $z = 0 To UBound($IP) - 1

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

    $Port = 31758
    $ConnectedSocket = TCPConnect($IP, $Port)
    If $ConnectedSocket = -1 Then
    MsgBox(16, "Error", "Es ist bei dem Verbindungsversuch ein Fehler aufgetreten, vermutlich ist kein Server gestartet!")
    Exit
    Else
    MsgBox("", "Erfolg", "$ConnectedSocket: " & $ConnectedSocket)
    EndIf

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

    Call("_Senden")
    ;HotKeySet("^s", "_Senden") ; ctrg + s
    While 1
    $Empfang = TCPRecv($ConnectedSocket, 9999)
    If $Empfang <> "" Then
    MsgBox(0, "Nachricht", $Empfang)
    EndIf
    Sleep(500)
    WEnd
    Next

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

    Func _Senden()
    $Nachricht = InputBox("Nachricht senden Client", "Schreibe deine Nachricht")
    If $Nachricht <> "" Then
    TCPSend($ConnectedSocket, $Nachricht)
    EndIf
    EndFunc ;==>_Senden

    [/autoit]

    p.s. danke für eure hilfe