Results 1 to 3 of 3
  1. #1
    Star Lounger
    Join Date
    Feb 2005
    Posts
    50
    Thanks
    6
    Thanked 0 Times in 0 Posts

    Starting a New Process (Excel 2000 & 2003)

    I would like to be able to initiate a new process from within Excel, for example to open a .DOC or .JPG file. I'm able to get the VB Shell command to work for .EXE files but don't know how to go about opening any file that has a recognised Type (eg .doc .jpeg). Any advice would be appreciated.

    regards

  2. #2
    WS Lounge VIP sdckapr's Avatar
    Join Date
    Jul 2002
    Location
    Pittsburgh, Pennsylvania, USA
    Posts
    11,225
    Thanks
    14
    Thanked 342 Times in 335 Posts

    Re: Starting a New Process (Excel 2000 & 2003)

    An easy way is to use folowhyperlink instead of shell it automatically opens up the assosicated program

    <pre>ActiveWorkbook.FollowHyperlink _
    Address:="C:PathMyFile.jpg", _
    NewWindow:=True</pre>


    Steve

  3. #3
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Starting a New Process (Excel 2000 & 2003)

    Alternatively, you can use the ShellExecute API function. See the thread starting at <post:=254,691>post 254,691</post:>.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •