zone97 Posted April 12, 2008 Share Posted April 12, 2008 Hello, I'm new here and have a few questions. BTW, Excelent program.... I would like to know if there is a way to change the title bar icon? [found the tray icon setting.] Can you use and icon file for above? Can "needed" files be compiled into the exe so you end up with only one file? Thanks. BTW, I did search and couldnt find these answers... Thanks. Spoiler WinSizer 2.1 (01/04/2017) - Download - [ Windows Layout Manager ]Folder+Program (12/23/2016) - Download - [ USB Shortcut Creator ] Link to comment Share on other sites More sharing options...
BrettF Posted April 12, 2008 Share Posted April 12, 2008 Hello, I'm new here and have a few questions. BTW, Excelent program.... I would like to know if there is a way to change the title bar icon? [found the tray icon setting.] Can you use and icon file for above? Can "needed" files be compiled into the exe so you end up with only one file? Thanks. BTW, I did search and couldnt find these answers... Thanks.Hi and welcome to the forums! The function you are looking for is GUISetIcon ( iconfile [, iconID [, winhandle]] ). Cheers! Brett Vist my blog!UDFs: Opens The Default Mail Client | _LoginBox | Convert Reg to AU3 | BASS.au3 (BASS.dll) (Includes various BASS Libraries) | MultiLang.au3 (Multi-Language GUIs!)Example Scripts: Computer Info Telnet Server | "Secure" HTTP Server (Based on Manadar's Server)Software: AAMP- Advanced AutoIt Media Player | WorldCam | AYTU - Youtube Uploader Tutorials: Learning to Script with AutoIt V3Projects (Hardware + AutoIt): ArduinoUseful Links: AutoIt 1-2-3 | The AutoIt Downloads Section: | SciTE4AutoIt3 Full Version! Link to comment Share on other sites More sharing options...
therks Posted April 12, 2008 Share Posted April 12, 2008 And FileInstall for the second question coincidentally. My AutoIt Stuff | My Github Link to comment Share on other sites More sharing options...
zone97 Posted April 12, 2008 Author Share Posted April 12, 2008 Hi and welcome to the forums! The function you are looking for is GUISetIcon ( iconfile [, iconID [, winhandle]] ). Cheers! Brett Thank you for the information, however here is a snippit of my code... TraySetIcon("Shell32.dll",-134) GUISetIcon("Shell32.dll",-134) The top works, the bottom does not. the taskbar icon and title bar icon stay the same. Spoiler WinSizer 2.1 (01/04/2017) - Download - [ Windows Layout Manager ]Folder+Program (12/23/2016) - Download - [ USB Shortcut Creator ] Link to comment Share on other sites More sharing options...
zone97 Posted April 12, 2008 Author Share Posted April 12, 2008 And FileInstall for the second question coincidentally.Thank you for this info as well. I noticed when reading the help on this command, that on exicution it is extracted to a predefined location. Could I assume then that if you want to clean up after yourself you would need to issue some delete commands to remove these files? Spoiler WinSizer 2.1 (01/04/2017) - Download - [ Windows Layout Manager ]Folder+Program (12/23/2016) - Download - [ USB Shortcut Creator ] Link to comment Share on other sites More sharing options...
MrCreatoR Posted April 12, 2008 Share Posted April 12, 2008 here is a snippit of my code... TraySetIcon("Shell32.dll",-134) GUISetIcon("Shell32.dll",-134) The top works, the bottom does not. the taskbar icon and title bar icon stay the same. It's work for me: #include <GuiConstants.au3> $GUI = GUICreate("Test Script", 300, 200) TraySetIcon("Shell32.dll",-134) GUISetIcon("Shell32.dll", -134) GUICtrlCreateButton("Button", 20, 40, 60, 20) GUISetState(@SW_SHOW, $GUI) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd What version of AutoIt you are using? and on what system? Could I assume then that if you want to clean up after yourself you would need to issue some delete commands to remove these files? Yes, you need to delete (FileDelete/DirRemove) manualy all FileInstalls to clean after your app is exit. Spoiler Using OS: Win 7 Professional, Using AutoIt Ver(s): 3.3.6.1 / 3.3.8.1 AutoIt Russian Community My Work... Spoiler Projects: ATT - Application Translate Tool {new}| BlockIt - Block files & folders {new}| SIP - Selected Image Preview {new}| SISCABMAN - SciTE Abbreviations Manager {new}| AutoIt Path Switcher | AutoIt Menu for Opera! | YouTube Download Center! | Desktop Icons Restorator | Math Tasks | KeyBoard & Mouse Cleaner | CaptureIt - Capture Images Utility | CheckFileSize ProgramUDFs: OnAutoItErrorRegister - Handle AutoIt critical errors {new}| AutoIt Syntax Highlight {new}| Opera Library! | Winamp Library | GetFolderToMenu | Custom_InputBox()! | _FileRun UDF | _CheckInput() UDF | _GUIInputSetOnlyNumbers() UDF | _FileGetValidName() UDF | _GUICtrlCreateRadioCBox UDF | _GuiCreateGrid() | _PathSplitByRegExp() | _GUICtrlListView_MoveItems - UDF | GUICtrlSetOnHover_UDF! | _ControlTab UDF! | _MouseSetOnEvent() UDF! | _ProcessListEx - UDF | GUICtrl_SetResizing - UDF! | Mod. for _IniString UDFs | _StringStripChars UDF | _ColorIsDarkShade UDF | _ColorConvertValue UDF | _GUICtrlTab_CoverBackground | CUI_App_UDF | _IncludeScripts UDF | _AutoIt3ExecuteCode | _DragList UDF | Mod. for _ListView_Progress | _ListView_SysLink | _GenerateRandomNumbers | _BlockInputEx | _IsPressedEx | OnAutoItExit Handler | _GUICtrlCreateTFLabel UDF | WinControlSetEvent UDF | Mod. for _DirGetSizeEx UDF Examples: ScreenSaver Demo - Matrix included | Gui Drag Without pause the script | _WinAttach()! | Turn Off/On Monitor | ComboBox Handler Example | Mod. for "Thinking Box" | Cool "About" Box | TasksBar Imitation Demo Like the Projects/UDFs/Examples? Please rate the topic (up-right corner of the post header: Rating ) * === My topics === * ================================================== ================================================== AutoIt is simple, subtle, elegant. © AutoIt Team Link to comment Share on other sites More sharing options...
Zedna Posted April 12, 2008 Share Posted April 12, 2008 (edited) Simpler way is here - Just place that 1 line at top of your AU3 script:#AutoIt3Wrapper_icon=your_icon.icoAnd compile your script from Scite4AutoIt3 editor (by F7).You must have file your_icon.ico at script directory at compile time only.After compilation is this icon inside output EXE and it's used as main icon also for your GUI window without using GUISetIcon. Edited April 12, 2008 by Zedna Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
zone97 Posted April 12, 2008 Author Share Posted April 12, 2008 It's work for me: I had to change 2 lines and use the code you supplied, those lines were... $GUI = GUICreate("Test Script", 300, 200) GUISetState(@SW_SHOW, $GUI) I was using only GUICreate("Test Script", 300, 200) GUISetState() Like this. Spoiler WinSizer 2.1 (01/04/2017) - Download - [ Windows Layout Manager ]Folder+Program (12/23/2016) - Download - [ USB Shortcut Creator ] Link to comment Share on other sites More sharing options...
zone97 Posted April 12, 2008 Author Share Posted April 12, 2008 Simpler way is here - Just place that 1 line at top of your AU3 script: #AutoIt3Wrapper_icon=your_icon.ico And compile your script from Scite4AutoIt3 editor (by F7). You must have file your_icon.ico at script directory at compile time only. After compilation is this icon inside output EXE and it's used as main icon also for your GUI window without using GUISetIcon. I tried the #AutoIt3Wrapper_icon=template.ico and it didn't seem to cause the compiled application to have the icon i selected... I used a program to extract the icon file, and put it in the same folder as the au3 before compiling. Nothing happened? Thanks. Spoiler WinSizer 2.1 (01/04/2017) - Download - [ Windows Layout Manager ]Folder+Program (12/23/2016) - Download - [ USB Shortcut Creator ] Link to comment Share on other sites More sharing options...
Zedna Posted April 12, 2008 Share Posted April 12, 2008 (edited) I tried the #AutoIt3Wrapper_icon=template.ico and it didn't seem to cause the compiled application to have the icon i selected... I used a program to extract the icon file, and put it in the same folder as the au3 before compiling. Nothing happened? Thanks.As I said: Download and install latest Scite4AutoIt3 editor first. Here is link: http://www.autoitscript.com/autoit3/scite/downloads.shtmlThen compile your script from Scite4AutoIt3 editor (by F7). Edited April 12, 2008 by Zedna Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
zone97 Posted April 12, 2008 Author Share Posted April 12, 2008 As I said: Download and install latest Scite4AutoIt3 editor first. Here is link: http://www.autoitscript.com/autoit3/scite/downloads.shtmlThen compile your script from Scite4AutoIt3 editor (by F7).That did the trick, but only for compite, got "go" it does not. But not that big of a deal. Thanks. Spoiler WinSizer 2.1 (01/04/2017) - Download - [ Windows Layout Manager ]Folder+Program (12/23/2016) - Download - [ USB Shortcut Creator ] 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