matwachich Posted February 6, 2012 Posted February 6, 2012 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!ToolBar icons.zip
LarsJ Posted February 6, 2012 Posted February 6, 2012 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. Controls, File Explorer, ROT objects, UI Automation, Windows Message MonitorCompiled code: Accessing AutoIt variables, DotNet.au3 UDF, Using C# and VB codeShell menus: The Context menu, The Favorites menu. Shell related: Control Panel, System Image ListsGraphics related: Rubik's Cube, OpenGL without external libraries, Navigating in an image, Non-rectangular selectionsListView controls: Colors and fonts, Multi-line header, Multi-line items, Checkboxes and icons, Incremental searchListView controls: Virtual ListViews, Editing cells, Data display functions
matwachich Posted February 6, 2012 Author Posted February 6, 2012 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.
UEZ Posted February 6, 2012 Posted February 6, 2012 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 Please don't send me any personal message and ask for support! I will not reply! Selection of finest graphical examples at Codepen.io The own fart smells best! ✌Her 'sikim hıyar' diyene bir avuç tuz alıp koşma!¯\_(ツ)_/¯ ٩(●̮̮̃•̃)۶ ٩(-̮̮̃-̃)۶ૐ
matwachich Posted February 7, 2012 Author Posted February 7, 2012 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 progressThanks all
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now