AutoHotkey Community

It is currently May 26th, 2012, 3:48 pm

All times are UTC [ DST ]




Post new topic Reply to topic  [ 12 posts ] 
Author Message
 Post subject: Gui, hyperlinks
PostPosted: November 14th, 2004, 2:18 am 
Offline

Joined: November 8th, 2004, 12:46 am
Posts: 1271
It might be useful to be able to incorporate hyperlinks into the gui.

for example:

Gui, Url, someone@place.co.uk

~ displays email address as a link with the Url command.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 14th, 2004, 6:33 am 
Offline

Joined: March 2nd, 2004, 3:36 pm
Posts: 10720
You can simulate a text link with something like this working example:

Gui, Font, underline
Gui, Add, Text, cBlue gMyLink, This is clickable like a hyperlink.
Gui, Font, norm
Gui, Show
return

MyLink:
Run, mailto:someone@place.co.uk
return


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 15th, 2004, 4:17 am 
Offline

Joined: November 8th, 2004, 12:46 am
Posts: 1271
It works for the email address link, but for some reason I am getting an error message with the following script, when I click on the website address link:

Code:
Gui, Font, underline
Gui, Add, Text, cBlue gMyLink, www.google.com
Gui, Font, norm

Gui, Font, underline
Gui, Add, Text, cBlue gMyMail, someone@place.com
Gui, Font, norm

Gui, Show
return

MyLink:
Run, www.google.com
return

MyMail:
Run, mailto: someone@place.com
return


The error message:

Code:
Error: Failed attempt to launch program or document:
Action: <www.google.com>
Params: <>

The current thread will exit.

Specifically: The system cannot find the file specified.

   Line#
   005: Gui,Add,Text,cBlue gMyLink,www.google.com
   006: Gui,Font,norm
   009: Gui,Font,underline
   010: Gui,Add,Text,cBlue gMyMail,someone@place.com
   011: Gui,Font,norm
   013: Gui,Show
   014: Return
--->   020: Run,www.google.com
   021: Return
   024: Run,mailto: someone@place.com
   025: Return
   027: Exit
   028: Exit


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 15th, 2004, 11:30 am 
Offline

Joined: August 26th, 2004, 3:11 pm
Posts: 80
Location: Chelsea - MA, USA
Try to use "http://www.google.com".

_________________
Working now on:
NumpadMouse v2 (Draw)
top-recode project (private server script) (pkodev)


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 15th, 2004, 12:41 pm 
Offline

Joined: November 8th, 2004, 12:46 am
Posts: 1271
deguix, I get the same error when I do that.

It works fine if I amend the run command to include the browser..

Code:
MyLink:
Run, %ProgramFiles%/Mozilla Firefox/firefox.exe www.google.com
return


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 15th, 2004, 12:57 pm 
Offline

Joined: March 2nd, 2004, 3:36 pm
Posts: 10720
It might have something to do with the default browser not being file-associated with HTTP URLs. Perhaps it only affects certain browsers. Has anyone else had this problem?


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 15th, 2004, 2:02 pm 
Offline
User avatar

Joined: August 11th, 2004, 1:47 am
Posts: 5347
Location: UK
No, running URLs is fine for me. I'm on IE6 by the way.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 16th, 2004, 1:16 am 
Offline

Joined: November 8th, 2004, 12:46 am
Posts: 1271
.url files are still associated with IE though its no longer installed on my computer.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 16th, 2004, 6:30 pm 
Offline

Joined: September 7th, 2004, 9:20 pm
Posts: 275
Location: France
Try SetBrowser to change the default browser.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 16th, 2004, 7:44 pm 
Offline

Joined: July 2nd, 2004, 11:53 pm
Posts: 207
Quote:
.url files are still associated with IE though its no longer installed on my computer.


How'd you get it off?


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 16th, 2004, 7:59 pm 
Offline

Joined: November 8th, 2004, 12:46 am
Posts: 1271
thanks Nemroth.

savage, I just deleted the files from the Internet Explorer folder.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 30th, 2005, 10:00 pm 
Code:
IEradicator:
Run, %ProgramFiles%/Mozilla Firefox/firefox.exe http://www.litepc.com/ieradicator.html
return


:wink:


Report this post
Top
  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 12 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: No registered users and 2 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group