Search found 1160 matches

by ShadowThief
20 Sep 2023 23:04
Forum: DOS Batch Forum
Topic: is there a DOS command for running a program with windows 98 compatibility?
Replies: 11
Views: 10679

Re: is there a DOS command for running a program with windows 98 compatibility?

nnnmmm wrote:
20 Sep 2023 20:59
i found this line in website set __COMPAT_LAYER=WIN98, but i dont know how to use it
That's the entire command; there's nothing else.
https://stackoverflow.com/questions/378 ... 3#37881453
by ShadowThief
20 Sep 2023 13:02
Forum: DOS Batch Forum
Topic: is there a DOS command for running a program with windows 98 compatibility?
Replies: 11
Views: 10679

Re: is there a DOS command for running a program with windows 98 compatibility?

Traditionally you right-click the application, go to Properties, go to the Compatibility tab, and pick the version you want compatibility with.

Windows 11 doesn't let you go older than Vista, so you may want to check out https://pcem-emulator.co.uk/ instead.
by ShadowThief
19 Sep 2023 20:22
Forum: DOS Batch Forum
Topic: [solved] cmd window only displays 16 colors with O/S reinstall
Replies: 5
Views: 4195

Re: cmd window only displays 16 colors with O/S reinstall

There's a registry setting you'll have to change because it's not enabled by default: https://superuser.com/a/1300251

Code: Select all

REG ADD HKCU\CONSOLE /f /v VirtualTerminalLevel /t REG_DWORD /d 1
by ShadowThief
18 Sep 2023 12:21
Forum: DOS Batch Forum
Topic: [solved] cmd window only displays 16 colors with O/S reinstall
Replies: 5
Views: 4195

Re: cmd window only displays 16 colors with O/S reinstall

It almost sounds like you installed an older version of Windows that doesn't support VT100 sequences.
by ShadowThief
18 Sep 2023 11:38
Forum: DOS Batch Forum
Topic: How to interrupt script by closing the CMD window with any key?
Replies: 7
Views: 27705

Re: How to interrupt script by closing the CMD window with any key?

Well you need to press any key twice because the first key ends the timeout command and the second key ends the pause command.

Very odd that timeout doesn't care about the w key though.
by ShadowThief
23 Aug 2023 02:12
Forum: DOS Batch Forum
Topic: avoid trailing space when piping to CLIP [SOLVED]
Replies: 6
Views: 5449

Re: avoid trailing space when piping to CLIP

The interpreter moves things around before it gets executed, so the line that actually gets run is

Code: Select all

SET/P=TEXT 0<NUL  | CLIP
You can see this by running your line by itself in a script with no @echo off
by ShadowThief
07 Aug 2023 19:42
Forum: DOS Batch Forum
Topic: Wrong Color of texts [SOLVED]
Replies: 4
Views: 2256

Re: Wrong Color of texts

In my experience, people choosing custom colors in the options is extremely rare (in the thirty-odd years that I've been using a computer, you're the only person I've ever heard of who's actually done it). I wouldn't worry too much about other people changing their colors. Also, it isn't possible to...
by ShadowThief
06 Aug 2023 16:47
Forum: DOS Batch Forum
Topic: Wrong Color of texts [SOLVED]
Replies: 4
Views: 2256

Re: Wrong Color of texts

Correct, the values of the color command are indices of the array of colors that are normally set in the registry, which you've changed in your settings.
by ShadowThief
06 Aug 2023 10:57
Forum: DOS Batch Forum
Topic: Native compress files in windows [SOLVED]
Replies: 6
Views: 2621

Re: Native compress files in windows [SOLVED]

Nice, I'm glad someone forked Frank Westlake's code.
by ShadowThief
03 Aug 2023 17:19
Forum: DOS Batch Forum
Topic: Native compress files in windows [SOLVED]
Replies: 6
Views: 2621

Re: Native compress files in windows

There are several options available, but makecab is probably your best bet. https://stackoverflow.com/questions/280 ... s-with-bat
by ShadowThief
03 Aug 2023 15:05
Forum: DOS Batch Forum
Topic: Bat script to shutdown computers and txt file
Replies: 3
Views: 1680

Re: Bat script to shutdown computers and txt file

Why are you parsing the output of type? You can just interact with the file directly in the for loop. for /f "usebackq delims=" %%A in ("PCNAME.txt") do shutdown /s /f /t 0 /m \\%%A (note that I'm assuming that the PC names don't have the \\ prefix in the text file that they need to be passed to the...
by ShadowThief
24 Jul 2023 11:42
Forum: DOS Batch Forum
Topic: Unable to produce truthful info about deletion or lack of thereof [SOLVED]
Replies: 8
Views: 2311

Re: Unable to produce truthful info about deletion or lack of thereof

Why do you even want the "There was nothing to delete" message? Whether there was or was not anything in the folders before the script was run, there is currently nothing in the folders after the fact. The message is useless.
by ShadowThief
19 Jul 2023 12:56
Forum: DOS Batch Forum
Topic: Finding cause of "The filename, directory name, or volume label syntax is incorrect" error when deleting files [SOLVED]
Replies: 11
Views: 3508

Re: Finding cause of "The filename, directory name, or volume label syntax is incorrect" error when deleting files blunt

wmic adds an extra carriage return (\r) at the end of its output (see https://www.dostips.com/forum/viewtopic.php?f=3&t=4266 for more details). A carriage return moves the cursor to the beginning of the line, so Processing Drive:[ is displayed, then the cursor is moved to the start of the line, and ...
by ShadowThief
15 Jul 2023 10:54
Forum: DOS Batch Forum
Topic: Forum issue: answering without being logged produces unnecessary error
Replies: 2
Views: 1332

Re: Forum issue: answering without being logged produces unnecessary error

Have you considered briefly glancing at the top right corner of the webpage to make sure you're logged in before trying to post?
by ShadowThief
13 Jul 2023 19:18
Forum: DOS Batch Forum
Topic: Unable to produce truthful info about deletion or lack of thereof [SOLVED]
Replies: 8
Views: 2311

Re: Unable to produce truthful info about deletion or lack of thereof

Delete the folder instead of emptying it, then use if exist to see if the folder is there. dir will always return something when it's inside of a folder that exists, so it's always going to return an %errorlevel% of zero.