Jump to content

Recommended Posts

Posted

In the help file for v3.1.1.103, there is a sample script which has the following line:

TraySetIcon("warning")

The help file shows it as:

TraySetIcon ( [iconfile [, iconID] )

the above example only has a 'filename' nothing more. Where is this aboe example pulling the warning icon from? is it defaulting to the shell32.dll ?

Is it an internal reference? if so, what other options/values are available?

Thanks for your time and assistance.

Van

Posted

maybe this sample help you:

#Include <Constants.au3>

#NoTrayIcon

Opt("TrayMenuMode",1) ; Default tray menu items (Script Paused/Exit) will not be shown.

$exititem = TrayCreateItem("Exit")

TraySetState()

$start = 0

While 1

$msg = TrayGetMsg()

If $msg = $exititem Then ExitLoop

$diff = TimerDiff($start)

If $diff > 1000 Then

TraySetIcon("Shell32.dll",Random(0,100,1))

$start = TimerInit()

EndIF

WEnd

Exit

Posted

maybe this sample help you:

#Include <Constants.au3>

#NoTrayIcon

Opt("TrayMenuMode",1) ; Default tray menu items (Script Paused/Exit) will not be shown.

$exititem = TrayCreateItem("Exit")

TraySetState()

$start = 0

While 1

$msg = TrayGetMsg()

If $msg = $exititem Then ExitLoop

$diff = TimerDiff($start)

If $diff > 1000 Then

TraySetIcon("Shell32.dll",Random(0,100,1))

$start = TimerInit()

EndIF

WEnd

Exit

No... that didn't hit the point I was trying to make. the script you specified (which I saw and which made me wonder about the trayseticon("warning") ) actually has a DLL and the icon reference pointer specified. thanks, though.

Van

Posted

Appears to be an undocumented feature. Quick trial and error revealed the following (and I imagine these are the main ones since these are the icons you have have for a MsgBox):

stop

question

warning

info

Great... As long as it's undocumented, I know don't feel half as stupid as I did earlier for not finding it.

Thanks.

Van

P.S. I said... "as I did earlier for 'not finding it.'" :lmao:

Posted (edited)

#Include <Constants.au3>

#NoTrayIcon

Opt("TrayMenuMode",1)

$show_tray = TrayCreateItem("About this Program")

...

run dispaly "TrayCreateItem" is Unknown function name

help me !

Edited by sxmuse

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
×
×
  • Create New...