Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 14
Default Using VBA to close a running application

Hi,

I'd like to have some VBA code in excel that will close a running app
if it's open.

Now I've found some code that closes all apps of a type (ie kills all
instances of msaccess.exe), but I want to close just certain access
db's, not all of them.

I've tried:

killstring = "taskkll /f /fi windowtitle eq filename : database
(Access 2000 file format) - Microsoft Access"
Call Shell(killstring, vbhide)

But this doesn't seem to work.

Are there any other solutions?

Thanks
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 79
Default Using VBA to close a running application

On 10 Ott, 11:57, macroapa wrote:
Hi,

I'd like to have some VBA code in excel that will close a running app
if it's open.

Now I've found some code that closes all apps of a type (ie kills all
instances of msaccess.exe), but I want to close just certain access
db's, not all of them.

I've tried:

killstring = "taskkll /f /fi windowtitle eq filename : database
(Access 2000 file format) - Microsoft Access"
Call Shell(killstring, vbhide)

But this doesn't seem to work.

Are there any other solutions?

Thanks



Hi macroapa.
See: http://support.microsoft.com/kb/210518/en-us
Regards
Eliano
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
Application.Quit Does not Close the Application [email protected] Excel Programming 6 October 8th 09 10:32 PM
Application.Close N1KO Excel Programming 2 April 24th 09 11:14 AM
Before Close Event Hide all Worksheets then Close Application RyanH Excel Programming 0 January 24th 08 03:15 PM
difference application.quit & application.close Pierre via OfficeKB.com[_2_] Excel Programming 4 November 8th 05 07:55 PM
macro to close excel application other than application.quit mary Excel Programming 1 September 14th 04 03:43 PM


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