PDA

View Full Version : Solved: REmove CTRL + Click to open a hyperlink



Alasbabylon
08-03-2005, 02:49 PM
I have been asked to solve a problem with a group of monthly reports to managers and directors. It seems these guys can't remember to use CTRL + Click top follow a hyperlink. And, they don't want to be tasked with changing their settings. How do I set up these docs so they automatically change the setting? I tried a macro, but can't make it work right.


With Options

.CtrlClickHyperlinkToOpen = False

End With

End Sub

:banghead:

Ken Puls
08-03-2005, 04:13 PM
Hi there,

Not much of a word guy at all, but does this not work? Code in the ThisDocument module:

Private Sub Document_Open()
Options.CtrlClickHyperlinkToOpen = False
End Sub

I think that should change it when the doc is opened. A word guru could verify this for you though...

EDIT: Just tested and seems to work fine on 2003! :)

xCav8r
08-03-2005, 08:15 PM
If they can't figure out how to hold CTRL when clicking a link, then asking them to run a document you send to them might be too much if their macro security level is set to high. If their startup locations are pointing to someplace on the network, then I'd propagate the setting change with that; otherwise, if their startup locations point to a place on their local drives, then I'd use whatever login admin utility you have to copy a .dot to that directory. Then on a subsequent login, I'd check to see if the .dot exists and delete it.

Also, I'd put it into AutoExec. I'm sure the Moose will weigh in with his opinion as well.

MOS MASTER
08-04-2005, 10:30 AM
Hi there,

Not much of a word guy at all, but does this not work?

Hey did you get permission to post in this Forum! :motz2: :rofl:

No really Ken that should work if it's a document else use Document_New() if it's a Template. (And I think it's the latter) :yes

MOS MASTER
08-04-2005, 10:36 AM
If they can't figure out how to hold CTRL when clicking a link, then asking them to run a document you send to them might be too much if their macro security level is set to high. If their startup locations are pointing to someplace on the network, then I'd propagate the setting change with that; otherwise, if their startup locations point to a place on their local drives, then I'd use whatever login admin utility you have to copy a .dot to that directory. Then on a subsequent login, I'd check to see if the .dot exists and delete it.

Also, I'd put it into AutoExec. I'm sure the Moose will weigh in with his opinion as well.

I'm right here buddy! :yes

Hi and Welcome to VBAX..Alasbabylon! :hi:

I'm thinking in the same direction as Marco.

But I would use the User templates folder or Workgroup templates folder to store a Global Normal.dot for ALL users.

That File would hold the House Formatting for the company and all global settings like Options CTRL+Click!

Remember User Templates is better cause if you where to use Workgroup and one of them is smart enough to put a Normal.dot in his User Template directory then that one is being used instead of the corporate one!

So you point the User Template to a shared Network drive and let them read from it. All of this can be done with Group Policy if you are in a domain and your administrater knows his way in the Active Directory.

But Ken't option should work just the same if you want it to work for separate documents.

Again a Global Add-in could be a sollution as well in the Start-up folder.

HTH, :whistle:

Alasbabylon
08-04-2005, 11:06 AM
I just need a way to put this in the document itself. No templates, no network. The document gets updated quarterly. It goes out to a select group of folks, which may change from quarter to quarter. And some folks are going to be part of a new organization that is merging with us and we don't know what they have on their machines.
I tried putting this text in New Macros:

Private Sub Document_Open()
Options.CtrlClickHyperlinkToOpen = False
End Sub

But the CTRL + Click is still checked.
What did I do wrong?

MOS MASTER
08-04-2005, 11:16 AM
I tried putting this text in New Macros:

Private Sub Document_Open()
Options.CtrlClickHyperlinkToOpen = False
End Sub


Hi, :yes

Did you read Ken't post?

Like he mentioned this code should be Pasted in to the class Module ThisDocument! Because it's a Eventhandler and those need to be in Class modules!

So in the VBE press CTRL+R and in the left (Project explorer) double click ThisDocument and paste your code Save | Close and reopen your document.

You're there! :whistle:

PS..NewMacro's is a normal module that is created automaticly when you record a macro.

HTH,

MOS MASTER
08-04-2005, 11:18 AM
Ps if you want to use a normal module like Newmacros you can use a "AutoMacro"!

Like:
Sub AutoOpen()
Options.CtrlClickHyperlinkToOpen = False
End Sub


HTH, :whistle:

Alasbabylon
08-04-2005, 11:36 AM
:cloud9: Thank you all SO MUCH! I just wasn't understanding where to put the code before. This works! :cloud9:

MOS MASTER
08-04-2005, 11:42 AM
:cloud9: Thank you all SO MUCH! I just wasn't understanding where to put the code before. This works! :cloud9:

Glad we could help you! :thumb

Ken you've solved a Word thread! :clap: :rofl:

Ken Puls
08-04-2005, 12:40 PM
Ken you've solved a Word thread! :clap: :rofl:

ROTFL! Who woulda thunk, it eh?

MOS MASTER
08-04-2005, 12:42 PM
ROTFL! Who woulda thunk, it eh?

Indeed I'm baffeld you have hidden skills! :p

Anne Troy
08-05-2005, 09:40 PM
Indeed I'm baffeld you have hidden skills! :p

You're not the only one, Joost.

:rofl:

MOS MASTER
08-06-2005, 02:34 PM
You're not the only one, Joost.

:rofl:

:funnyashe :funnyashe

Ken Puls
08-06-2005, 11:04 PM
Indeed I'm baffeld you have hidden skills! :p

This almost hurts me! LOL! One day I'm going to post in the Outlook forum too... you just wait and see! :rotlaugh:

MOS MASTER
08-07-2005, 01:23 PM
This almost hurts me! LOL! One day I'm going to post in the Outlook forum too... you just wait and see! :rotlaugh:

Nah it won't...you're a thoughie! :yes (Can't wait...)