amaasbier Posted March 28, 2008 Share Posted March 28, 2008 (edited) Hey there,im new to AutoIt and trying to do something, which has been asked houndred times. But as I already know how it should work, I don't know how it actually does.I tried using the following example script directly from the AutoIt-site, but for now to no avail. The script should embed some icons and show them on a button, but it doesn't. Using ResourceHacker I as well don't find any additional resources. The only way to find an icon in a compiled .exe afterwards is to define the custom icon in Aut2Exe.Adding Extra Ico's to the program resources (LINK)#AutoIt3Wrapper_Res_Icon_Add=C:\ICONS\People\RUN.ICO #AutoIt3Wrapper_Res_Icon_Add=C:\ICONS\People\RUN2.ICO #AutoIt3Wrapper_Res_Icon_Add=C:\Program Files (x86)\AutoIt3\Icons\au3.ico #AutoIt3Wrapper_Res_Icon_Add=C:\Program Files (x86)\AutoIt3\Icons\filetype1.ico #AutoIt3Wrapper_Res_Icon_Add=C:\Program Files (x86)\AutoIt3\Icons\filetype2.ico #AutoIt3Wrapper_Res_Icon_Add=C:\Program Files (x86)\AutoIt3\Icons\filetype3.ico #AutoIt3Wrapper_Res_Icon_Add=C:\Program Files (x86)\AutoIt3\Icons\filetype-blank.ico #include <GUIConstants.au3> GUICreate("Demo resource ICO's") $h_Button1 = GUICtrlCreateButton("my picture button", 10, 20, 40, 40, $BS_ICON) GUISetState() For $x = 0 To 7 $rc = TraySetIcon(@ScriptFullPath, -$x) $rc2 = GUICtrlSetImage($h_Button1, @ScriptFullPath, -$x) If $x < 3 Then TrayTip("Default ico:" & $x, "TraySetIcon rc:" & $rc & @LF & "GUICtrlSetImage rc:" & $rc2, 3) Else TrayTip("New ico:" & $x, "TraySetIcon rc:" & $rc & @LF & "GUICtrlSetImage rc:" & $rc2, 3) EndIf Sleep(2000) Next GUIDelete()As you may have noticed I am on a Windows XP x64 Pro machine. That's why i altered the folders.All icons are accessible and work 100% fine when im copypasting the files' location to the explorer.For now I have no clue what I'm doing wrong. I don't think it has to do with compatibility problems though, since I as well tested the script on a WinXP x86 system.Thanks, amaasbier Edited March 28, 2008 by amaasbier Link to comment Share on other sites More sharing options...
amaasbier Posted March 28, 2008 Author Share Posted March 28, 2008 I noticed that the sample GUI (SampleControls.au3) doesn't compile correctly. There never is any icon displayed, but the sample avi and gif works fine. Accessing the compiler via rightclick menu, Au2Exe or from within SciTe doesn't seem to make a difference. Not even x86/x64 mode. I always end up with the same result: Link to comment Share on other sites More sharing options...
Developers Jos Posted March 28, 2008 Developers Share Posted March 28, 2008 Did you install the Full version of SciTE4AutoIt3 first ? SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
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