Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 47
Default Hyperlink focus and default email program ?

Hi;

Is there a way, preferrably using macros / VBA, to change the action of
Hyperlinks?

Right now, some of my users find that if they inadvertently click once on a
hyperlink they end up getting an email program ('Word") which they didn't
intend. Can I change calling hyperlink action to a double click or
Ctrl-click or something more deliberate.

Secondly, how can I set up a preferred email program for Excel hyperlinks
for each different user? Baseing it on login name would do.

Regards Bill
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default Hyperlink focus and default email program ?

You can't change the real hyperlink, but you can use the beforedouble click
event to react to a double click on the cell. Put a string in the cell and
make it look like a hyperlink by formatting it as blue with an underline.

Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As
Boolean)
if Target.count 1 then exit sub
if not intersect(Target,Range("B9,B13,B16,B23")) is nothing then
Cancel = False
select Case Target.Address(0,0)
Case "B9"
ThisWorkbook.FollowHyperlink "actual hyperlink string"
Case "B13"
Application.Goto Worksheets("Sheet6").Range("F11"), True
Case

and so forth

There is a registry setting for the default mail program, but I don't have
any information on it. Perhaps someone else will jump in.

You might want to use the hyperlink Mailto: command. That should use the
default mail program.

http://tinyurl.com/zc44h

See Gary's post and of course Ron de Bruin's links.

--
Regards,
Tom Ogilvy

End Sub

"Bill Case" wrote:

Hi;

Is there a way, preferrably using macros / VBA, to change the action of
Hyperlinks?

Right now, some of my users find that if they inadvertently click once on a
hyperlink they end up getting an email program ('Word") which they didn't
intend. Can I change calling hyperlink action to a double click or
Ctrl-click or something more deliberate.

Secondly, how can I set up a preferred email program for Excel hyperlinks
for each different user? Baseing it on login name would do.

Regards Bill

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I change the default email program in Excel 2007? wretchedcrust Setting up and Configuration of Excel 2 September 4th 13 12:21 AM
Default Program Dan Excel Discussion (Misc queries) 1 February 11th 09 12:53 AM
Default Program Dan Setting up and Configuration of Excel 0 February 11th 09 12:15 AM
VBA Program to Email-able Toolbar Sean Excel Programming 3 June 23rd 05 09:18 AM
Shut off email address from linking to email program? Java Jake Excel Worksheet Functions 6 December 31st 04 04:05 PM


All times are GMT +1. The time now is 12:32 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"