Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Macro to open other applications

Is it possible to run a macro within excel to open other
applications like word?

My macro keeps returning the following error: "File format
is not valid".

Thanks
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 25
Default Macro to open other applications

Look at the GetObject information. e.g,

Set WDApp = GetObject(, "Word.Application")


"Sherry" wrote in message
...
Is it possible to run a macro within excel to open other
applications like word?

My macro keeps returning the following error: "File format
is not valid".

Thanks



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default Macro to open other applications

You need more than GetObject, as the app may not be instantaited already.
Something like

On Error Resume Next
Set WDApp = GetObject(, "Word.Application")
If WDApp Is Nothing Then
Set WDApp = CreateObject("Word.Application")
If WDApp Is Nothing Then
Exit Sub
End If
End If

... do your stuff

--

HTH

RP

"Bill" wrote in message
...
Look at the GetObject information. e.g,

Set WDApp = GetObject(, "Word.Application")


"Sherry" wrote in message
...
Is it possible to run a macro within excel to open other
applications like word?

My macro keeps returning the following error: "File format
is not valid".

Thanks





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
Why does Exel open much slower than other applications? Andre Excel Discussion (Misc queries) 0 March 24th 09 08:37 PM
Can't open Excel files from other applications Paul Excel Discussion (Misc queries) 1 February 10th 09 01:43 PM
Open Microsoft Office Applications from another computer? mspm45 Excel Discussion (Misc queries) 3 July 30th 05 05:09 PM
Hide (visible+AD0-false) all open applications? Joe 90[_2_] Excel Programming 0 October 23rd 03 07:12 PM
Hide (visible+AD0-false) all open applications? Joe 90[_2_] Excel Programming 0 October 22nd 03 11:06 PM


All times are GMT +1. The time now is 11:15 AM.

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

About Us

"It's about Microsoft Excel"