Jump to content
Sign in to follow this  
casperha

how can i set the buttom icon

Recommended Posts

casperha

(ps : sorry my english is not good....)

if i use the script

GUICreate(" My GUI Icons")
Opt("GUICoordMode",1)

GUICreate("My GUI icon Race", 350,74,-1,-1)
GUICtrlCreateLabel ("", 331,0,1,74,5)
$n1=GUICtrlCreateIcon ("logo.exe", -1, 0,0,32,32)
$n2=GUICtrlCreateIcon ( @windowsdir & "\cursors\horse.ani", -1, 0,40,32,32)

GUISetState (@SW_SHOW)

Dim $a = 0, $b = 0
While ($a < 300) And ($b < 300)
  $a = $a + int(Random(0,1)+0.5)
  $b = $b + int(Random(0,1)+0.5)
  GUICtrlSetPos($n1, $a,0)
  GUICtrlSetPos($n2, $b,40)
  Sleep(20)
WEnd
sleep(1000)
oÝ÷ Ú'Ƕ¢rðY[z»§§¶Ú²HhÁƧǭ¶¢rèØ^nëm¢j+q©â±ëmè¢wÉbrJ'¶îØ^¦º ­©¦Ê'(+'¢Ø¡·j맶Ú&jG©+-²(¢x¬{W¡£+¶«¨¶ØZL¨¹ëÞ¯&èo+héiè¡jËkÊÚ.±ë(ë®*mjëh×6
#include <GUIConstants.au3>

;dim $n1 = GUICtrlCreateIcon ("logo.exe", -1, 0,0,32,32)

GUICreate("test",240,180)
$button1 = GUICtrlCreateButton ("1", 0,0,40,40,$BS_ICON)
GUICtrlCreateIcon ("logo.exe", -1, 0,0,32,32)
;GUICtrlSetImage (-1, $n1 , -1)
$button2 = GUICtrlCreateButton ("2", 40,00,40,40,$BS_ICON)
GUISetIcon ("logo.exe")
;GUICtrlSetImage (-1, "logo.exe",-1)
$button3 = GUICtrlCreateButton ("3", 80,00,40,40,$BS_ICON)
GUICtrlSetImage (-1, "shell32.dll",22)
$button4 = GUICtrlCreateButton ("4", 120,0,40,40,$BS_ICON)
GUICtrlSetImage (-1, "shell32.dll",23)
$button5 = GUICtrlCreateButton ("5", 160,0,40,40,$BS_ICON)
GUICtrlSetImage (-1, "shell32.dll",32)
$buttonclose = GUICtrlCreateButton ("close", 200,0,40,40,$BS_ICON)
GUICtrlSetImage (-1, "shell32.dll",28)
GUISetState()




; Run the GUI until the dialog is closed
While 1
    $msg = GUIGetMsg() 
    If $msg = $GUI_EVENT_CLOSE Then ExitLoop
Wend

GUIDelete()

but also can't set on the buttom....

Edited by casperha

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×