Sign in to follow this  
Followers 0
NewForAutoit

HELP IN ITEM

5 posts in this topic

#1 ·  Posted (edited)

Does anyone can help me to work the following script is

the problem that I come not to serve as item .

#include <GUIConstants.au3>
Opt("WinTitleMatchMode", 2)
Opt("TrayMenuMode", 1)
$reduireitfem = TrayCreateItem("Tray")
$rffehh = TrayCreateItem("Show")
$reduireitem = TrayCreateItem("Exit")
$Form1 = GUICreate("Test Item", 302, 212, 193, 125)
GUISetState(@SW_SHOW)

While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit

    EndSwitch
WEnd
Edited by NewForAutoit

Share this post


Link to post
Share on other sites



You might try asking again. You either A: haven't provided enough information, B: didn't ask a proper question, or C: don't speak english and lost something in translation.

Share this post


Link to post
Share on other sites

Does anyone can help me to work the following script is

the problem that I come not to serve as item .

#include <GUIConstants.au3>
Opt("WinTitleMatchMode", 2)
Opt("TrayMenuMode", 1)
$reduireitfem = TrayCreateItem("Tray")
$rffehh = TrayCreateItem("Show")
$reduireitem = TrayCreateItem("Exit")
$Form1 = GUICreate("Test Item", 302, 212, 193, 125)
GUISetState(@SW_SHOW)

While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit

    EndSwitch
WEndoÝ÷ Ûú®¢×­¬¦zËë­ë¥ªÚµçë¢kaxeë,j¬£*.«Þ¶hnaèzÓ,©ÝN¶²ëL²)^w*.­×¦¡«­¢+Ø¥¹±Õ±ÐíU%
½¹ÍѹÑ̹ÔÌÐì()=ÁÐ ÅÕ½ÐíQÉå5¹Õ5½ÅÕ½Ðì°Ä¤((ÀÌØíÉեɥѴôQÉå
ÉÑ%Ñ´ ÅÕ½ÐíQÉäÅÕ½Ðì¤(ÀÌØíÉ¡ ôQÉå
ÉÑ%Ñ´ ÅÕ½ÐíM¡½ÜÅÕ½Ðì¤(ÀÌØíÉեɥѴôQÉå
ÉÑ%Ñ´ ÅÕ½Ðíá¥ÐÅÕ½Ðì¤(ÀÌØí½É´ÄôU%
ÉÑ ÅÕ½ÐíQÍÐ%Ñ´ÅÕ½Ðì°ÌÀÈ°ÈÄÈ°ÄäÌ°ÄÈÔ¤)U%MÑMÑÑ¡M]}M!=¤()]¡¥±Ä(ÀÌØí¹5ÍôU%Ñ5Í ¤(MÝ¥Ñ ÀÌØí¹5Í(
ÍÀÌØíU%}Y9Q}
1=M(á¥Ð(%¹MÝ¥Ñ ($($ÀÌØí¹QÉå5ÍôQÉåÑ5Í ¤(%MÝ¥Ñ ÀÌØí¹QÉå5Í($%
ÍÀÌØíÉեɥѴ($$%5Í ½à ØаÅÕ½ÐíQÉäÅÕ½Ðì°ÅÕ½ÐíQÉäÅÕ½Ðì¤($$$($%
ÍÀÌØíÉ¡ ($$%5Í  ½à ØаÅÕ½ÐíM¡½ÜÅÕ½Ðì°ÅÕ½ÐíM¡½ÜÅÕ½Ðì¤($$$($%
ÍÀÌØíÉեɥѴ($$%5Í ½à ØаÅÕ½Ðíá¥ÐÅÕ½Ðì°ÅÕ½Ðíá¥ÐÅÕ½Ðì¤($$%á¥Ð(%¹MÝ¥Ñ )]¹

:)


Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law

Share this post


Link to post
Share on other sites

I'm having some trouble understanding your description of the trouble, but I believe the problem you're having is the fact that you do not "handle" the messages from the Tray:

#include <GUIConstants.au3>
#Include <Constants.au3> ; Might also wanna include this

Opt("WinTitleMatchMode", 2)
Opt("TrayMenuMode", 1)

$reduireitfem = TrayCreateItem("Tray")
$rffehh = TrayCreateItem("Show")
$reduireitem = TrayCreateItem("Exit")
$Form1 = GUICreate("Test Item", 302, 212, 193, 125)

GUISetState(@SW_SHOW)

While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit
    EndSwitch
    
    $nMsg = TrayGetMsg() ; Get the tray message, and then we check it below. :)
    Switch $nMsg
        Case $reduireitfem
            ConsoleWrite("$reduireitfem was clicked" & @LF) ; just shows us what tray item was clicked
            ; Do something
        Case $rffehh
            ConsoleWrite("$rffehh was clicked" & @LF) ; just shows us what tray item was clicked
            ; Do something else
        Case $reduireitem
            Exit ; or do something more
    EndSwitch
WEnd

Share this post


Link to post
Share on other sites

Thanks You PsaltyDS and FreeFry

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  
Followers 0