Solved

No automatic document opening on app start

Posted on 1998-12-03
1
206 Views
Last Modified: 2013-11-20
I've created a MDI App with AppWizard. How do I prevent the
program from opening a default document when starting?
0
Comment
Question by:jntv
[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
 

Accepted Solution

by:
hap earned 50 total points
ID: 1325719
If you are using 5.0 or later the only changes that you have to make are in your InitInstance() member function of your application class:

After the line:
      ParseCommandInfo(cmdInfo);
and before the line:
      if (!ProcessShellCommand(cmdInfo)

add the following lines:
      // DON'T display a new MDI child window during startup!!!
      cmdInfo.m_nShellCommand = CCommandLineInfo::FileNothing;
 
(I don't recall how it was done previously, but I recall it was more obvious, so I'm sure that this will solve your problem)

Good Luck
Hap
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: Dialogs (1) modal - maintaining the database. Continuing from the ninth article about sudoku.   You might have heard of modal and modeless dialogs.  Here with this Sudoku application will we use one of each type: a modal dialog …
Introduction: Dialogs (2) modeless dialog and a worker thread.  Handling data shared between threads.  Recursive functions. Continuing from the tenth article about sudoku.   Last article we worked with a modal dialog to help maintain informat…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
In this video we outline the Physical Segments view of NetCrunch network monitor. By following this brief how-to video, you will be able to learn how NetCrunch visualizes your network, how granular is the information collected, as well as where to f…

707 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