Solved

Call my program itself.

Posted on 1999-01-25
1
165 Views
Last Modified: 2010-04-02
What is the difference between print banding and
non-banding ? Which is the better ?
What is the difference between programming in lazer printer
and HP Deskjet (670C)printer ?
How can I return the program after I sent WM_CLOSE to it( that means I want to close my program and after that it can
call itself again), like this :
 My program include 2 modun A and B. At the beginning, A can run or call B. If A call B, B is ruuning and when B finished it auto close the program and call again to the beginning (A run) . User only can close program only they close A.



0
Comment
Question by:longlong
[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
1 Comment
 
LVL 10

Accepted Solution

by:
viktornet earned 50 total points
ID: 1185128
you can use one of these...

WinExec()
ShellExecute()
CreateProcess()

then when you execute app B it would wait and see when A is gonna close down. When this happens your B programs does some stuff and runs back app A, and the process can continue on and on...

YOu can use WaitForSingleObject() so your program can wait until the other closes down...

Hope this helps...

-Viktor
--Ivanov
0

Featured Post

Industry Leaders: 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

Suggested Solutions

Introduction This article is a continuation of the C/C++ Visual Studio Express debugger series. Part 1 provided a quick start guide in using the debugger. Part 2 focused on additional topics in breakpoints. As your assignments become a little more …
C++ Properties One feature missing from standard C++ that you will find in many other Object Oriented Programming languages is something called a Property (http://www.experts-exchange.com/Programming/Languages/CPP/A_3912-Object-Properties-in-C.ht…
The goal of the video will be to teach the user the concept of local variables and scope. An example of a locally defined variable will be given as well as an explanation of what scope is in C++. The local variable and concept of scope will be relat…
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…

734 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