Jump to content



Photo

Gui Image List & Embedeed Icons in Exe


  • Please log in to reply
4 replies to this topic

#1 matwachich

matwachich

    Polymath

  • Active Members
  • PipPipPipPip
  • 215 posts

Posted 06 February 2012 - 07:03 PM

Hi every body!

I have a strange problem that i can't solve:
I made a GUI with a ToolBar, and i want to display custom icons in it.
It's OK if i don't compile the script and i try to add the icons into my ImageList directly from disque, but when i compile and embeed my icons in the Exe file, then my icons wont appear at all!

I made a simplified sample GUI to show you my problem, but here, it's another problem:
the first added icon won't appear, and the others (2) appear, and the standard compiled script's icons appear normally!

I really have a big headach in this!

Here is joined my script with the icons, please compile it to see the problem.

Thanks!

Attached Files









#2 LarsJ

LarsJ

    Adventurer

  • Active Members
  • PipPip
  • 139 posts

Posted 06 February 2012 - 08:57 PM

Should it not be 4,5,6 in stead of 5,6,7:

If @Compiled Then
_GUIImageList_AddIcon ($hToolBarImageListNorm, @ScriptFullPath, 4)
_GUIImageList_AddIcon ($hToolBarImageListNorm, @ScriptFullPath, 5)
_GUIImageList_AddIcon ($hToolBarImageListNorm, @ScriptFullPath, 6)
Else

When I Compile with Options without changing anything it works.

#3 matwachich

matwachich

    Polymath

  • Active Members
  • PipPipPipPip
  • 215 posts

Posted 06 February 2012 - 09:32 PM

Yep it's 4,5,6 the SciTE doc is false!

So now, i should at my other script why it doesn't work...

Il say when i find

PS: i can't post my whole script here, it's really big, and a bit complicated.

#4 UEZ

UEZ

    Never say never

  • MVPs
  • 3,612 posts

Posted 06 February 2012 - 09:45 PM

This seems to be working:

...         If @Compiled Then             _GUIImageList_AddIcon ($hToolBarImageListNorm, @AutoItExe, 4)             _GUIImageList_AddIcon ($hToolBarImageListNorm, @AutoItExe, 5)             _GUIImageList_AddIcon ($hToolBarImageListNorm, @AutoItExe, 6)         Else             _GUIImageList_AddIcon ($hToolBarImageListNorm, "btn_newFile.ico")             _GUIImageList_AddIcon ($hToolBarImageListNorm, "btn_newFolder.ico")             _GUIImageList_AddIcon ($hToolBarImageListNorm, "btn_delete.ico")         EndIf ...


Br,
UEZ

 
The own fart smells best!
Her 'sikim hıyar' diyene bir avuç tuz alıp koşma!
¯\_(ツ)_/¯


#5 matwachich

matwachich

    Polymath

  • Active Members
  • PipPipPipPip
  • 215 posts

Posted 07 February 2012 - 12:41 AM

OH MY GOD!!!
It was only a mistake in variable name! Cause i have 2 ImageLists in my script, and i added all the icons to one image list only!

PS: This was for Scite Project Manager, you can download a snapshoot of my actual work to test if you want! Remeber: it's a work in progress

Thanks all




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users