Spoiler anzeigen
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <GUIListBox.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ### Form=
$Form2 = GUICreate("Mailadressen", 345, 254, 302, 218)
;~ GUISetIcon("D:\007.ico")
$ListBox1 = GUICtrlCreateList("", 8, 8, 137, 201, BitOR($LBS_STANDARD, $LBS_EXTENDEDSEL))
GUICtrlSetData(-1, "test@mail.de|[email='monster@mail.de'][/email]|autoit@mail.de")
$Button1 = GUICtrlCreateButton(">>", 156, 15, 30, 25, $WS_GROUP)
$Button2 = GUICtrlCreateButton("<<", 157, 81, 31, 25, $WS_GROUP)
$ListBox2 = GUICtrlCreateList("", 200, 8, 137, 201)
GUICtrlSetState(-1, $GUI_FOCUS)
$Button3 = GUICtrlCreateButton("&OK", 104, 225, 75, 25, $WS_GROUP)
$Button4 = GUICtrlCreateButton("&Cancel", 184, 225, 75, 25, $WS_GROUP)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
$msg = 0
While $msg <> $GUI_EVENT_CLOSE
$msg = GUIGetMsg()
Select
Case $msg = $Button1
$aIndex = _GUICtrlListBox_GetSelItems($ListBox1)
If $aIndex[0] > 0 Then
For $i = $aIndex[0] To 1 Step -1
$sText = _GUICtrlListBox_GetText($ListBox1, $aIndex[$i])
_GUICtrlListBox_DeleteString($ListBox1, $aIndex[$i])
_GUICtrlListBox_AddString($ListBox2, $sText)
Next
EndIf
Case $msg = $Button2
GUICtrlSetData($ListBox2, "")
Case $msg = $Button3
MsgBox(0, "", "Mailadressen")
Case $msg = $Button4
MsgBox(0, "", "Ende", 2)
Exit
EndSelect
WEnd