LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default How do I execute other application(*.exe) from VBA(Excel) ?

Hello,
I also tried this, and initially it appeared to work. my executable is a
compiled fortran program. The executable works ok when I run it outside of
Excel, but when I use the shell command, it doesnt.

Sub run_for()
Dim retApp As Double
retApp = Shell("L:\methods\for.exe", vbMinimizedFocus)

End Sub

The .exe accesses an input file from within L:\methods. When I execute from
the subroutine, does it need a full pathname in the exe as opposed to just
the filename?

Bird


"robertdeniro" wrote:


-*Shell "C:\windows\ap1.exe", vbNormalFocus*-

Unless Ap1.exe is located in a folder that's in the system path, you'll
have to specify the full path to the file.


--
robertdeniro
------------------------------------------------------------------------
robertdeniro's Profile: http://www.excelforum.com/member.php...o&userid=14173
View this thread: http://www.excelforum.com/showthread...hreadid=396096


 
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
macro to close excel application other than application.quit mary Excel Programming 1 September 14th 04 03:43 PM
Application level events no longer execute R Avery Excel Programming 1 June 4th 04 01:21 AM
tried to execute application from VBA Domagoj Vulin[_2_] Excel Programming 0 July 23rd 03 09:58 PM
tried to execute application from VBA Tom Ogilvy Excel Programming 1 July 23rd 03 09:56 PM
tried to execute application from VBA Bill Lunney Excel Programming 0 July 23rd 03 02:05 PM


All times are GMT +1. The time now is 02:00 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"