Hey.
Ich könnte ein bisschen hilfe bei meiner GUI brauchen, ohne GUI klappt alles super nur ich hab ein problem mit $URL.
Wie kann ich es machen das anstatt:
$ping = InputBox ("Ping","Server Adresse oder Hostname eingeben",""," M")
$pingtime = Ping ($ping)
Das was in der $URL eingegeben wird(bei der gui) als $ping gespeichert wird.
Tut mir leid falsch ich mich ein bisschen komisch ausdrücke, weiß nicht wie ich das anders erklären soll.
C
#NoTrayIcon
#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ### Form=C:\Users\Firstshoot\Desktop\ping.kxf
$Form1 = GUICreate("Form1", 291, 151, 192, 124)
GUISetCursor (2)
GUISetBkColor(0x000000)
$URL = GUICtrlCreateInput("URL", 45, 10, 200, 21)
GUICtrlSetBkColor(-1, 0x800000)
$Start = GUICtrlCreateButton("Start", 45, 50, 200, 50, 0)
GUICtrlSetBkColor(-1, 0x800000)
GUICtrlSetCursor (-1, 2)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $URL
Case $Start
if $pingtime Then
MsgBox (0,"Status","Server: Online - Time: " & $pingtime)
Else
MsgBox (0,"Status","Server: Offline" & @error)
EndIf
EndSwitch
WEnd
Alles anzeigen
Also es ist quasi eine inputbox ($URL) und ein Button ($Start), das was in der Inputbox eingegeben wird soll irgentwie gespeichert werden damit ich es per button überprüfen/ausführen kann.
Ich bedanke mich schon recht herzlich.![]()