Home | Blog | Software | Reviews and Features | Forum | Help | Donate | About us
topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • December 08, 2016, 08:26:57 AM
  • Proudly celebrating 10 years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Author Topic: Running an external command from with Microsoft Word?  (Read 5940 times)

dluby

  • Charter Member
  • Joined in 2006
  • ***
  • Posts: 220
    • View Profile
    • Donate to Member
Running an external command from with Microsoft Word?
« on: May 27, 2008, 09:13:48 AM »
Hi all,

Does anyone know how to insert a link to run an external command from within Microsoft Word (2003)?  I'd like to run a command/utility (or whatever) in a similar fashion to the way you can insert Hyperlinks to other documents.

Thanks

Damian

Perry Mowbray

  • N.A.N.Y. Organizer
  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 1,817
    • View Profile
    • Donate to Member
Re: Running an external command from with Microsoft Word?
« Reply #1 on: May 27, 2008, 09:22:03 AM »
You should just be able to add a hyperlink to a file in the normal manner:

Screenshot - 28_05_2008 , 12_25_45 AM.png
« Last Edit: May 27, 2008, 09:26:21 AM by Perry Mowbray »

kfitting

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 578
    • View Profile
    • Donate to Member
Re: Running an external command from with Microsoft Word?
« Reply #2 on: May 27, 2008, 09:52:20 AM »
What about commandline arguments?  Like try to open an excel document with some commandline options... I couldnt get that to work.

Kevin

f0dder

  • Charter Honorary Member
  • Joined in 2005
  • ***
  • Posts: 9,029
  • [Well, THAT escalated quickly!]
    • View Profile
    • f0dder's place
    • Read more about this member.
    • Donate to Member
Re: Running an external command from with Microsoft Word?
« Reply #3 on: May 27, 2008, 10:06:00 AM »
Wouldn't something like that be blocked with default security settings?
- carpe noctem

Perry Mowbray

  • N.A.N.Y. Organizer
  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 1,817
    • View Profile
    • Donate to Member
Re: Running an external command from with Microsoft Word?
« Reply #4 on: May 27, 2008, 10:09:56 AM »
The best I could do was to create a shortcut with the commandline options in the shortcut and add that as the object of the hyperlink.

Messy  :(

Perry Mowbray

  • N.A.N.Y. Organizer
  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 1,817
    • View Profile
    • Donate to Member
Re: Running an external command from with Microsoft Word?
« Reply #5 on: May 27, 2008, 10:10:30 AM »
Wouldn't something like that be blocked with default security settings?

On my version Word asks me if I'm sure...

dluby

  • Charter Member
  • Joined in 2006
  • ***
  • Posts: 220
    • View Profile
    • Donate to Member
Re: Running an external command from with Microsoft Word?
« Reply #6 on: May 27, 2008, 10:12:38 AM »
I managed to get a batch file to work that launched the command with parameters, but Word does warn you about the possibility of the file containing a virus and the command prompt window stays open until I close the utility!

kfitting

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 578
    • View Profile
    • Donate to Member
Re: Running an external command from with Microsoft Word?
« Reply #7 on: May 27, 2008, 11:04:42 AM »
Yeah, we set security to low.  I know it sounds silly and naive but we arent concerned about security in this case... but, it appears that you cant get word to correctly launch hyperlinks with commandline parameters.  We couldnt even get the file to launch if you have the parameters in the link.

Kevin