rawrr Posted February 14, 2008 Share Posted February 14, 2008 Im making a tray icon that gives you your IP when you hover over it. Can anyone help me with the command to give your ip? This is very useful to me because I need my IP a lot. So, please, help me. =] Thanks! P.S. Im new. =] Well ive been registered, but I didn't do anything basically yet. Link to comment Share on other sites More sharing options...
JustinReno Posted February 14, 2008 Share Posted February 14, 2008 @IPAddress1. Link to comment Share on other sites More sharing options...
rawrr Posted February 14, 2008 Author Share Posted February 14, 2008 (edited) Hehe. Thanks I just figured that out when I typed IP in the script. =] Thanks. EDIT: How about the hover part? I have to right click to get it. =[ lol Edited February 14, 2008 by rawrr Link to comment Share on other sites More sharing options...
z0mgItsJohn Posted February 14, 2008 Share Posted February 14, 2008 Theres 2 Different IP Functions #Include <INet.au3> ; Include For Function _GetIP $IP_Address_1 = _GetIp () MsgBox (0, "Notice", "Your IP Address Is : " & $IP_Address_1,0) ; Or $IP_Address_2 = @IPAddress1 MsgBox (0, "Notice", "Your IP Address Is : " & $IP_Address_2,0) ; This One Is Different From The Other One... P.S. For Any Other Help You Can Add Me On MSN... -- 'maxell225@hotmail.com' Latest Projects :- New & Improved TCP Chat Link to comment Share on other sites More sharing options...
TurionAltec Posted February 14, 2008 Share Posted February 14, 2008 Hehe. Thanks I just figured that out when I typed IP in the script. =] Thanks. EDIT: How about the hover part? I have to right click to get it. =[ lol look at the TraySetOnEvent() function specialID= $TRAY_EVENT_MOUSEOVER = -11 Then use ToolTip() or TrayTip() to display the IP, or clipput() to put it in the clipboard, or whatever. Link to comment Share on other sites More sharing options...
rawrr Posted February 14, 2008 Author Share Posted February 14, 2008 I kind of get what you guys mean. Can you make a script so I can compare? Link to comment Share on other sites More sharing options...
JustinReno Posted February 14, 2008 Share Posted February 14, 2008 Compare what? Link to comment Share on other sites More sharing options...
rawrr Posted February 14, 2008 Author Share Posted February 14, 2008 Scripts.. To see if I did it right. Link to comment Share on other sites More sharing options...
z0mgItsJohn Posted February 14, 2008 Share Posted February 14, 2008 Here Ya Go #Include <INet.au3> Opt("TrayMenuMode",1) Global $IP_Address = _GetIP () TraySetState () TraySetToolTip ("IP Address : " & $IP_Address) While 1 Sleep (250) HotKeySet ("{Esc}", "_Exit") Sleep (250) WEnd Func _Exit () Exit EndFunc Latest Projects :- New & Improved TCP Chat Link to comment Share on other sites More sharing options...
qazwsx Posted February 14, 2008 Share Posted February 14, 2008 While 1 Sleep (250) HotKeySet ("{Esc}", "_Exit") Sleep (250) WEnd Is there a reason the Hotkeyset is in the while loop? Escape is often not a good hotkey to use becasue its default function is to exit the gui. Link to comment Share on other sites More sharing options...
GaryFrost Posted February 14, 2008 Share Posted February 14, 2008 #include <INet.au3> #NoTrayIcon Opt("OnExitFunc", "_Exit") Opt("TrayMenuMode", 1) Opt("TrayOnEventMode", 1) Global $IP_Address _Get_IP() $Tray_GetIP = TrayCreateItem("Get IP") TrayItemSetOnEvent(-1, "_Get_IP") TrayCreateItem("") $Tray_Exit = TrayCreateItem("Exit") TrayItemSetOnEvent(-1, "_Exit") TraySetState() While 1 TraySetToolTip("IP Address : " & $IP_Address) Sleep(50) WEnd Func _Get_IP() $IP_Address = _GetIP() EndFunc ;==>_Get_IP Func _Exit() Exit EndFunc ;==>_Exit SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference. 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