DOS window stays open when executing from a batch file

Discussion in 'C++' started by Alan, Jun 23, 2005.

  1. Alan

    Alan Guest

    When I run an executable directly (there's no console output), an
    MS-DOS windows opens briefly, then closes. When I call my executable
    from a batch file, the window stays open and says "finished." I have to
    close it manually.

    Any idea on why this might be the case? Thanks, Alan
     
    Alan, Jun 23, 2005
    #1
    1. Advertising

  2. Alan wrote:
    > When I run an executable directly (there's no console output), an
    > MS-DOS windows opens briefly, then closes. When I call my executable
    > from a batch file, the window stays open and says "finished." I have to
    > close it manually.
    >
    > Any idea on why this might be the case? Thanks, Alan


    Pardon me, what's your C++ language question?
     
    Victor Bazarov, Jun 23, 2005
    #2
    1. Advertising

  3. Alan

    Alan Guest

    It's an executable from a C++ program. Pardon me if this is
    not appropriate for this forum. I am glad you are policing it. I
    suppose next I will be thrown to the ground and handcuffed.
     
    Alan, Jun 23, 2005
    #3
  4. Alan wrote:
    > It's an executable from a C++ program. Pardon me if this is
    > not appropriate for this forum. I am glad you are policing it. I
    > suppose next I will be thrown to the ground and handcuffed.
    >


    If I (and some others) weren't "policing" this forum, how the fcuk would
    _you_ know that it's not appropriate? You apparently haven't read the
    FAQ or the Welcome message or this newsgroup at all to understand what
    is and what isn't appropriate...
     
    Victor Bazarov, Jun 23, 2005
    #4
  5. Alan

    Alan Guest

    Read this FAQ. I was asking the question to determine whether
    or not there was something I could do in my C++ PROGRAM (sound
    familiar?) to avoid this problem I had never encountered before with a
    C++ PROGRAM. If not, then that answers my question. Thus, I think I
    should be allowed, oh great one, to ask the question here.

    If you`re so interested in me not wasting your time, why don`t
    you skip this thread and let someone else answer.
     
    Alan, Jun 23, 2005
    #5
  6. Alan wrote:
    > Read this FAQ. I was asking the question to determine whether
    > or not there was something I could do in my C++ PROGRAM (sound
    > familiar?) to avoid this problem I had never encountered before with a
    > C++ PROGRAM. If not, then that answers my question. Thus, I think I
    > should be allowed, oh great one, to ask the question here.
    >
    > If you`re so interested in me not wasting your time, why don`t
    > you skip this thread and let someone else answer.
    >


    Easy now...

    Many folks here use Operating Systems other than MS Windows.

    Your question is specific to the MS Windows link/loader and
    the folks in one of the MS VC newsgroups may be able to answer it.

    Regards,
    Larry
     
    Larry I Smith, Jun 24, 2005
    #6
  7. Alan

    Stephen Howe Guest

    > Read this FAQ. I was asking the question to determine whether
    > or not there was something I could do in my C++ PROGRAM (sound
    > familiar?) to avoid this problem I had never encountered before with a
    > C++ PROGRAM. If not, then that answers my question. Thus, I think I
    > should be allowed, oh great one, to ask the question here.
    >
    > If you`re so interested in me not wasting your time, why don`t
    > you skip this thread and let someone else answer.


    Sure. It is an OS problem, you can do somthing about, but since OS-specific
    problems are not covered here, only C++, I will refrain from answering. Now
    you know it is not C++.

    SH
     
    Stephen Howe, Jun 24, 2005
    #7
  8. Alan

    Alan Guest

    Thanks, Stephan. The best way in the future to refrain is to not click
    on the "Reply" button.
     
    Alan, Jun 24, 2005
    #8
  9. Alan

    rossum Guest

    On 23 Jun 2005 15:53:00 -0700, "Alan" <> wrote:

    [snip]
    >I was asking the question to determine whether
    >or not there was something I could do in my C++ PROGRAM (sound
    >familiar?) to avoid this problem

    [snip]

    There is nothing you can do in the C++ program, you will have to make
    a change to the batch file. You might find the "EXIT" command useful
    in this context.

    rossum


    The ultimate truth is that there is no ultimate truth
     
    rossum, Jun 24, 2005
    #9
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Leeor Chernov
    Replies:
    4
    Views:
    13,293
    Leeor Chernov
    Dec 15, 2005
  2. Ben Fairbank
    Replies:
    2
    Views:
    5,498
  3. =?Utf-8?B?bWF0bHlu?=

    creating a file within a subdir in DOS batch file

    =?Utf-8?B?bWF0bHlu?=, Sep 20, 2007, in forum: ASP .Net
    Replies:
    0
    Views:
    672
    =?Utf-8?B?bWF0bHlu?=
    Sep 20, 2007
  4. Simon Wigzell
    Replies:
    4
    Views:
    321
    Simon Wigzell
    Sep 15, 2003
  5. dorayme

    Dropdown menu stays open in IE7

    dorayme, Sep 17, 2008, in forum: Javascript
    Replies:
    2
    Views:
    167
    dorayme
    Sep 18, 2008
Loading...

Share This Page