Sign in to follow this  
Followers 0
oneLess

buttons with custom icons

5 posts in this topic

$iconpath = "d:\blablabla\"

$icon1 = "x.ico"

$icon2 = "exit2.ico"

$icon3 = "8096.ICO"

GuiCtrlCreateIcon($iconpath & $icon1,-1, 19, 19)

$ExitID = GUICtrlCreateButton( "Iesire" , 55, 55, 60, 60, $BS_ICON)

GUICtrlSetImage ($ExitID, $iconpath & $icon2) ;

$ShutID = GUICtrlCreateButton( "Shutdown" , 99, 99, 31, 31, $BS_ICON) ;33,33

GUICtrlSetImage ($ShutID, $iconpath & $icon3) ;

running .au3 or . exe i can see my icons on GUI till i move the 3 icons in other folder.

then i dont see on my gui the icons .

if i include with

fileinstall("d:\blablabla\x.ico" , "")

fileinstall("d:\blablabla\exit2.ico" , "")

fileinstall("d:\blablabla\8096.ICO" , "")

then (i run the .au3 from desktop) i get the 3 icons on my desktop .

how can i include in my .exe the 3 icons without copy them from exe file somewhere ?

i use already another icon for the .exe file .

Share this post


Link to post
Share on other sites



running .au3 or . exe i can see my icons on GUI till i move the 3 icons in other folder.

then i dont see on my gui the icons .

if i include with

then (i run the .au3 from desktop) i get the 3 icons on my desktop .

how can i include in my .exe the 3 icons without copy them from exe file somewhere ?

i use already another icon for the .exe file .

You HAVE to extract the pictures somewere in order to use them, a proper place would be the Temp folder:

msgbox(0,"",@TempDir)

Then on exit, delete the files again

$ButtonPic = @Tempdir & "\Pic.jpg"

Filedelete($ButtonPic)

Share this post


Link to post
Share on other sites

thanks for the replay .

ok , i did that after 2 hours o serching here .

just not pointed to a proper folder . i use "" for the path of dest.

so this is the way ? cannot include in , without extraction ?

thanks again .

Share this post


Link to post
Share on other sites

No I don't think thats possible ;)

Share this post


Link to post
Share on other sites

#5 ·  Posted (edited)

ok . i figure out with this .

but seems to have another problem .

the .au3 file work ok with temp. folder , but the compiled .exe

do not want to extract the 3 icons to temp folder !?

probably i made some wrong here ?

i use

fileinstall("D:\x.ico" , @TempDir, 1)

so , normally x.ico must to be

included already in my .exe file !?

/EDIT

work with

fileinstall("D:\x.ico" , @TempDir & "\", 1)

Edited by oneLess

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  
Followers 0