Jump to content
Sign in to follow this  

Change Title Picture

Recommended Posts

That makes no sense. Just convert the code. You have _SendMessage() in SendMessage.au3, see helpfile.

How will _SendMessage() help me? can you give an example to change, say Mozilla Firefox's picture in title?

Share this post

Link to post
Share on other sites

Ah, sorry!

You want to use the script to change a icon for another program ?

Im to fresh in the scripting world to help with that.

[font="helvetica, arial, sans-serif"]Hobby graphics artist, using gimp.Automating pc stuff, using AutoIt.Listening to music, using Grooveshark.[/font]Scripts:[spoiler]Simple ScreenshotSaves you alot of trouble when taking a screenshot!Don't remember what happened with this, but aperantly the exe is all i got.If you don't want to run it, simply don't._IsRun UDFIt figures out if the script has ben ran before based on the info in a ini file.If you don't want to use exactly what i wrote, you can use it as inspiration.[/spoiler]

Share this post

Link to post
Share on other sites

Google first result:

How To Change the Application Icon with Visual Basic


SendMessage & WM_SETICON

As I said this example does exactly what you want, it's easy to convert that code to Autoit.

You need just WinGetHandle() + LoadIcon and SendMessage (WM_SETICON) API functions.

Search this forum for examples with these API functions.

Edited by Zedna

Share this post

Link to post
Share on other sites

bucause i don`t know how is a handle of an icon or how to get it i try to retrieve one using _sendmessage() with WM_GETICON as msg, but i don´t get anything...

#include <SendMessage.au3>
Const $WM_SETICON = 0x0080 ; http://msdn.microsoft.com/en-us/library/ms632643
Const $WM_GETICON = 0x007F ; already declared if you use WinApiEx.au3 ;P ups!
Const $ICON_BIG = 1
Const $ICON_SMALL = 0
$winhndl = WinGetHandle("[CLASS:SciTEWindow]")
ConsoleWrite('@@ Debug(' & @ScriptLineNumber & ') : $winhndl = ' & $winhndl & @crlf & '>Error code: ' & @error & @crlf) ;### Debug Console
$autoiticon = _SendMessage($winhndl, $WM_GETICON, $ICON_SMALL)
ConsoleWrite('@@ Debug(' & @ScriptLineNumber & ') : $autoiticon = ' & $autoiticon & @crlf & '>Error code: ' & @error & @crlf) ;### Debug Console

sorry but still don´t get it... :huh2:

>"C:\Program Files (x86)\AutoIt3\SciTE\AutoIt3Wrapper\AutoIt3Wrapper.exe" /run /prod /ErrorStdOut /in "F:\Agustin\autoit\Foro Autoit\sendicon.au3" /autoit3dir "C:\Program Files (x86)\AutoIt3" /UserParams    
+>01:16:06 Starting AutoIt3Wrapper v.    Environment(Language:0C0A  Keyboard:0000040A  OS:WIN_7/  CPU:X64 OS:X64)
>Running AU3Check (  from:C:\Program Files (x86)\AutoIt3
+>01:16:06 AU3Check ended.rc:0
>Running:(\Program Files (x86)\AutoIt3\autoit3_x64.exe "F:\Agustin\autoit\Foro Autoit\sendicon.au3"    
@@ Debug(7) : $winhndl = 0x00000000001103BA
>Error code: 0
@@ Debug(9) : $autoiticon = 0
>Error code: 0
+>01:16:06 AutoIT3.exe ended.rc:0
>Exit code: 0    Time: 1.343

Also i found this but i don´t know how to implement a VB.NET native method to autoit ;)


Edited by monoscout999

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  

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Create New...