Primary Navigation

CMD Window Doesn't Close

To all, How to cause the CMD window to close after launching an application via a hyperlink in a topic within an NTP Outline document? Here s an example of

Message 1 of 2
, Apr 23, 2011

0 Attachment

To all,

How to cause the CMD window to close after launching an application via a
hyperlink in a topic within an NTP Outline document?

Here's an example of what I mean:

The following is a hyperlink in a topic within an outline

[cmd.exe /c start AntbarLaunch.bat]

The batch file follows after one blank line:

@ECHO off
:: Open Windows Explorer in Antbar directory
:: By RAS 4/24/2011
cls
:: a long line follows
c:\windows\explorer.exe C:\"Documents and Settings\RAS\Application
Data\Mozilla\Firefox\Profiles\d3skf7th.default\antbar"

The batch file has ended immediately above.

If I understand the info in the following reference, the "c" switch in the
cmd.exe command should cause the CMD window to close after launching Windows
Explorer:

Instead, Windows Explorer opens with the correct directory displayed, but
the CMD window remains open. By adding the "exit" statement at the bottom of
the batch file, the CMS widow does close, but Windows Explorer is not the
focused application (although the desired folder is selected). If I
eliminate the "c" switch, the batch file doesn't run at all.

Why is the "c" switch not working?

NTP 6.2/fv running under Win7 Pro 64-bit.

Thank you for your help.

Ray Shapp

[Non-text portions of this message have been removed]

Dave

Hi have you tried this approach below and call it something.cmd and launch in nts ... @echo off title Batch File Testing echo Hello World echo. pause

Message 2 of 2
, Apr 25, 2011

0 Attachment

Hi
have you tried this approach below and call it something.cmd and launch in
nts
-----------------------------
@echo off
title Batch File Testing

> To all,
>
> How to cause the CMD window to close after launching an application via a
> hyperlink in a topic within an NTP Outline document?
>
> Here's an example of what I mean:
>
>
> The following is a hyperlink in a topic within an outline
>
> [cmd.exe /c start AntbarLaunch.bat]
>
> The batch file follows after one blank line:
>
> @ECHO off
> :: Open Windows Explorer in Antbar directory
> :: By RAS 4/24/2011
> cls
> :: a long line follows
> c:\windows\explorer.exe C:\"Documents and Settings\RAS\Application
> Data\Mozilla\Firefox\Profiles\d3skf7th.default\antbar"
>
> The batch file has ended immediately above.
>
> If I understand the info in the following reference, the "c" switch in the
> cmd.exe command should cause the CMD window to close after launching
> Windows
> Explorer:
>
> http://www.computerhope.com/cmd.htm
>
> Instead, Windows Explorer opens with the correct directory displayed, but
> the CMD window remains open. By adding the "exit" statement at the bottom
> of
> the batch file, the CMS widow does close, but Windows Explorer is not the
> focused application (although the desired folder is selected). If I
> eliminate the "c" switch, the batch file doesn't run at all.
>
> Why is the "c" switch not working?
>
> NTP 6.2/fv running under Win7 Pro 64-bit.
>
> Thank you for your help.
>
> Ray Shapp
>
>
> [Non-text portions of this message have been removed]
>
>
>
> ------------------------------------
>
> Yahoo! Groups Links
>
>
>

Your message has been successfully submitted and would be delivered to recipients shortly.