Tooltip auf Label

10/22/2011 16:11 Njahs#1
Hallo Epvp...
Ich wollte mal fragen , ob man ein Tooltip erstellen kann , dass
nur erscheint , wenn die Maus auf einem BEstimmtem Label
zeigt / steht.....

Danke :D
10/22/2011 16:26 BlackHybrid#2
PHP Code:
#include <GUIConstantsEx.au3>

Opt('MustDeclareVars'1)

Example()

Func Example()
    
Local $msg
    
    GUICreate
("My GUI control tip")  ; will create a dialog box that when displayed is centered

    GUICtrlCreateLabel
("my label"1020)
    
GUICtrlSetTip(-1"tip of my label")
    
    
GUISetState()

    ; 
Run the GUI until the dialog is closed
    
While 1
        $msg 
GUIGetMsg()
        
        If 
$msg $GUI_EVENT_CLOSE Then ExitLoop
    WEnd
EndFunc   
;==>Example 
Aus der Helpfile ;)
10/22/2011 20:34 Njahs#3
Hätte da noch ne frage um List...
HTML Code:
    $jobsl = GuiCtrlCreateList("Miner", 157, 100, 100, 100)
    GuiCtrlSetData(-1, "Farmer|Monster Hunter|NetherJokey|Woodcutter", "Miner")
Das ist der Ausschnitt aus meinem Script , nun
will ich , wenn "Farmer" in der Liste ausgewählt ist ,
etwas geschieht , doch ich weiss nicht wie...

HTML Code:
 If $jobsl = "Miner" then ...
geht z.b. nicht
10/22/2011 20:38 omer36#4
guictrlread($jobsl)
10/22/2011 21:52 Njahs#5
Quote:
Originally Posted by omer36 View Post
guictrlread($jobsl)
Und wie kann ich es die Ganze Zeit mit einer If - Abfrage
überprüfen?

PHP Code:
#include <ButtonConstants.au3> 
#include <EditConstants.au3> 
#include <GUIConstantsEx.au3> 
#include <SliderConstants.au3>
#include <StaticConstants.au3>
#include <GUIConstantsEx.au3>
#include <ProgressConstants.au3>
#Include <GuiButton.au3>
#include <WindowsConstants.au3>
#include <Misc.au3>
#include <GuiComboBoxEx.au3>

#NoTrayIcon

TraySetState()
TraySetToolTip("HelpTool Liberty-Minecraft!")

$Form1 GUICreate("Menü"450350250150)

GUISetBkColor(0x00E0FFFF)
    
GUISetFont(9300)

$tab GUICtrlCreateTab(1010425300)

[...]
    

    
$jobs GUICtrlCreateTabItem("Jobs")
    
$j GUICtrlCreateLabel("Die Jobs"18060)
    
GUICtrlSetFont(-194004)
    
$jobslist GuiCtrlCreateList(""157100100100)
    
GuiCtrlSetData(-1"Miner|Farmer|MonsterHunter|NetherJokey|Woodcutter""")

[...]

$jobslistx guictrlread($jobslist)

While 
1
    $msg 
GUIGetMsg ()
    Switch 
$msg
        
    
Case $GUI_EVENT_CLOSE
        
Exit
    Case 
$icon1
        GuiSetState 
(@SW_SHOW,$hp)
    Case 
$icon2
        GuiSetState 
(@SW_SHOW,$forum)
    Case 
$icon3
        GuiSetState 
(@SW_SHOW,$epvp)
    Case 
$backh
        GuiSetState 
(@SW_HIDE,$hp)
        
$oIEh.Stop
    
Case $backf
        GuiSetState 
(@SW_HIDE,$forum)
        
$oIEf.Stop
    
Case $backe
        GuiSetState 
(@SW_HIDE,$epvp)
        
$oIEe.Stop
    
Endswitch
    
WEnd 
10/22/2011 22:09 omer36#6
Ich weiß ja nicht, wo bzw wann du das überprüfen willst....

halt wie du es gemacht hattest,

If GUICtrlRead($jobsl) = "Miner" then ...
10/22/2011 22:28 Njahs#7
Quote:
Originally Posted by omer36 View Post
Ich weiß ja nicht, wo bzw wann du das überprüfen willst....

halt wie du es gemacht hattest,

If GUICtrlRead($jobsl) = "Miner" then ...
Ich will es die Ganze zeit überprüfen , btw.
es muss irgendwie in die While schleife ,
doch wenn ich es versuche , passiert
nicht , wenn ich Miner in der Liste auswähle...

Edit:// Habs nun mit Adlibregister hinbekommen...
Trotzdem danke!
10/22/2011 22:40 omer36#8
Machs doch in die Haupt-Schleife, zwischen
EndSwitch und WEnd.