Visual Basic hyperlink

J

Jasper Recto

How do I accomplish this task:

I want to be able to put a hyperlink in a word document. I want the link to
run a certain visual basic command.
That command is: Shell("C:\WINNT\Explorer.exe /n, L:\Vantage Documents\PN
12268700\", 1)

This command opens a folder in windows explorer in a single pane view

I can't use a traditional hyperlink because it opens the folder in a double
pane view.
How would I create a script to run that command and how would I make it a
hyperlink?

Any suggestions would be greatly appreciated!

Thank you!
Jasper
 
W

Word Heretic

G'day "Jasper Recto" <[email protected]>,

use a macrobutton field styled up to look like a hyperlink (ie, style
the field hyperlink char style)


Jasper Recto said:
How do I accomplish this task:

I want to be able to put a hyperlink in a word document. I want the link to
run a certain visual basic command.
That command is: Shell("C:\WINNT\Explorer.exe /n, L:\Vantage Documents\PN
12268700\", 1)

This command opens a folder in windows explorer in a single pane view

I can't use a traditional hyperlink because it opens the folder in a double
pane view.
How would I create a script to run that command and how would I make it a
hyperlink?

Any suggestions would be greatly appreciated!

Thank you!
Jasper

Steve Hudson

Word Heretic, Sydney, Australia
Tricky stuff with Word or words for you.
Email (e-mail address removed)
Products http://www.geocities.com/word_heretic/products.html

Replies offlist may require payment.
 
J

Jonathan West

Hi Jasper.

Put the command into a Word macro. Then create a MACROBUTTON field within
the document that calls the macro.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top