Computing.Net > Forums > Windows XP > EXIT in BATCH file

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Click here to start participating now! Also, check out the New User Guide.

EXIT in BATCH file

Reply to Message Icon

Name: vivcn4acid
Date: June 9, 2009 at 03:23:17 Pacific
OS: Xp
Subcategory: General
Comment:

Im working in XP and created a batch file with an extension .cmd and not .bat...when i execute its working fine but the DOS window is not closing...

my program is

@Echo Off
setlocal
Set _InputFile=\\as-sisccsfsv02\Paybase2dev\DelDups\config.txt
Set _Data1=""
For /F "tokens=1,2* delims=:" %%A IN (%_InputFile%) DO Set _Data%%A=%%C
IF "%_Data1%"=="" set _Data1=1
set _


sqlplus %_Data3%/%_Data4%@%_Data5% @%_Data2% %_Data1%

endlocal
@CLS

i dono where and how to place the EXIT and also whether to use cls or exit...since im using a connection string and tryin to connect to execute queries in sql..its a bit confusing..please advice..thanks in advance



Sponsored Link
Ads by Google

Response Number 1
Name: Mechanix2Go
Date: June 9, 2009 at 04:09:41 Pacific
Reply:

It SHOULD pfamous last words] suffice to put exit as the last line.

CLS clears the screen. Nothing to do with exit.


=====================================
If at first you don't succeed, you're about average.

M2


0
Reply to Message Icon

Related Posts

See More


Takes forever to open External Portable Hard Dr...



Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Windows XP Forum Home


Sponsored links

Ads by Google


Results for: EXIT in BATCH file

difference b/w %%g and %g% in batch file www.computing.net/answers/windows-xp/difference-bw-g-and-g-in-batch-file/176113.html

BATCH FILES IN XP? www.computing.net/answers/windows-xp/batch-files-in-xp/8304.html

Exiting Dos Batch File www.computing.net/answers/windows-xp/exiting-dos-batch-file/129443.html