Solved

Closing a Dos window

Posted on 1998-10-27
5
123 Views
Last Modified: 2010-04-30
How can I close a dos window within Vb after it has quit running?
0
Comment
Question by:sear
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 12

Expert Comment

by:mark2150
ID: 1441844
You need to set the properties of the program to "Close on Exit"...

M

0
 

Author Comment

by:sear
ID: 1441845
I don't think this is the answer I'm looking for. I want to be able to run a program from vb such as
shell("c:\compress.exe setup.exe setup.ex_") and when the program is finished I want it to close automatically.
Jr.
0
 
LVL 12

Accepted Solution

by:
mark2150 earned 10 total points
ID: 1441846
Right. Set the properties of C:\COMPRESS.EXE to "Close on exit" and it'll fold the tent when it's done.

M

0
 

Author Comment

by:sear
ID: 1441847
Thank you does exactly what I want.
0
 
LVL 12

Expert Comment

by:mark2150
ID: 1441848
If you set the property to "Run minimized" you'll not see a DOS window while it's flying either...

I have ExecCmd function code that *waits* for child to finish before letting your code continue. SHELL is a async process and parent continues to fly while child runs. Sometimes is good, sometimes is not if you need data that child will produce.

If you need ExecCmd source hit me direct at mark_lambert@ntsc.navy.mil

M

0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

688 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question