#include <GUIConstantsEx.au3>
#include <ButtonConstants.au3>
#include <WindowsConstants.au3>
#NoTrayIcon
Local $Button_1, $Button_2, $Button_3, $Button_4, $Button_5, $msg, $hGUI
$hGUI = GUICreate("GUI с кнопкой")
Opt("GUICoordMode", 2)
$Button_1 = GUICtrlCreateButton("Запуск блокнота", 10, 20, 120)
$Button_2 = GUICtrlCreateButton("Тестовая кнопка", -1, 0)
GUICtrlSetBkColor(-1, 0x0)
GUICtrlSetColor(-1, 0xFFFFFF)
$Button_3 = GUICtrlCreateButton("-", -1, 10, 22, 22, $BS_ICON)
GUICtrlSetImage(-1, @SystemDir & '\shell32.dll', 42, 0)
$Button_4 = GUICtrlCreateButton("-", -1, 10, 40, 40, $BS_ICON + $BS_FLAT)
GUICtrlSetImage(-1, "shell32.dll", 46, 1)
$Button_5 = GUICtrlCreateButton("кнопка с рисунком bmp", -1, 10, 160, 160, $BS_PUSHLIKE + $BS_BITMAP)
GUICtrlSetImage(-1, "oemlogo.bmp")
GUISetState()
While 1
Switch GUIGetMsg()
Case $GUI_EVENT_CLOSE
ExitLoop
Case $Button_1
Run('notepad.exe')
Case $Button_2
GUICtrlSetData($Button_2, 'Новый текст')
Case $Button_3
GUICtrlSetImage($Button_3, @SystemDir & '\shell32.dll', 22, 0)
Case $Button_4
MsgBox(4096, 'Тест', 'Нажата кнопка со стилем плоской кнопки', 0, $hGUI)
Case $Button_5
MsgBox(4096, 'Тест', 'Нажата кнопка с BMP рисунком', 0, $hGUI)
EndSwitch
WEnd