Jump to content

Shortcut/Link/URL in TrayTip?


Recommended Posts

There seems to be two relevant posts on this subject in the forums here: one links to an outside tool (CPPToolTip v2.1), while the other seems to create something that looks like a link (but apparently doesn't work as a link).

So, does anyone have any code that works natively within AutoIt that can do this? I'd like to be able to click a link or a url in a traytip that could open a folder/file. I'd rather not have to run a GUI and try to detect mouse position & clicks, but rather a real link. Is this possible with AutoIt? Any help appreciated....

Edited by DrLarch
Link to comment
Share on other sites

  • Moderators

Something like this? One item for a URL and one for a folder

#include <IE.au3>
#NoTrayIcon
Opt("TrayMenuMode", 1)

TrayCreateItem("")
$google = TrayCreateItem("Google")
$explorer = TrayCreateItem("WinDir")
TraySetState()

While 1
    Local $msg = TrayGetMsg()
    If $msg = $google Then _IECreate("www.google.com")
If $msg = $explorer Then ShellExecute(@WindowsDir)
WEnd

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

I think he means the popup tooltip like this:

Posted Image

I looked into this possibility a while back and AutoIt couldn't do that at the time. Others suggested to create a borderless gui and put a link in there. Problem with that was it was only a rectangle, not the cool looking tooltip like the one in the picture.

Link to comment
Share on other sites

Something like this? One item for a URL and one for a folder

#include <IE.au3>
#NoTrayIcon
Opt("TrayMenuMode", 1)

TrayCreateItem("")
$google = TrayCreateItem("Google")
$explorer = TrayCreateItem("WinDir")
TraySetState()

While 1
Local $msg = TrayGetMsg()
If $msg = $google Then _IECreate("www.google.com")
If $msg = $explorer Then ShellExecute(@WindowsDir)
WEnd

Oh, that's useful too, JLogan3o13, but yes, abberration is right. I'm fiddling around with CPPToolTip v2.1, but it's going to take a while for me to get my head around that solution. Oh well. Thanks for the help.
Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...