Discussion forum for all Windows batch related topics.
Moderator: DosItHelp
-
Ed Dyreen
- Expert
- Posts: 1569
- Joined: 16 May 2011 08:21
- Location: Flanders(Belgium)
-
Contact:
#1
Post
by Ed Dyreen » 28 Jun 2011 23:48
☺
This is the command I use to prevent the console from closing on a syntax error:
Code: Select all
start "TST_noterm" "%COMSPEC%" /k "tst.CMD"
I've noticed this is not enough, the console still crashes on a logical error.
Is there anything that can be done about this, so I don't have to guess what went wrong ?
-
nitt
- Posts: 218
- Joined: 22 Apr 2011 02:43
#2
Post
by nitt » 29 Jun 2011 00:00
I tried your code but it crashed Chrome and Folding@Home... How am I supposed to implement this?
-
Ed Dyreen
- Expert
- Posts: 1569
- Joined: 16 May 2011 08:21
- Location: Flanders(Belgium)
-
Contact:
#3
Post
by Ed Dyreen » 29 Jun 2011 00:14
☺
It's a
question nitt, not an implementation. This works for XP:
Code: Select all
start "Title" "%COMSPEC%" /k "mybatch.???"
I simply start a new instance of cmd with the stay resident option /k, see cmd /? for help.
But the console still crashes on a logical error
-
orange_batch
- Expert
- Posts: 442
- Joined: 01 Aug 2010 17:13
- Location: Canadian Pacific
-
Contact:
#4
Post
by orange_batch » 04 Jul 2011 08:55
Can you give an example of a logical error?
-
Ed Dyreen
- Expert
- Posts: 1569
- Joined: 16 May 2011 08:21
- Location: Flanders(Belgium)
-
Contact:
#5
Post
by Ed Dyreen » 04 Jul 2011 16:23
☺
I mean like buffer overflow, I'm not very good in english so maybe i'm not expressing myself correctly. When using the push any string over endlocal technique with a string that is too big, the console will crash, even with the /k option