Installation, updates, general problem solving and assistance.
User avatar
Steven W
VIP
Posts: 2893
Joined: 2013-08-10 22:40

2020-12-12 22:04 »

TheMiningTeamYT wrote:
2020-12-12 01:53
Steven W wrote:
2020-12-12 00:37
But yea, is this what the corruption looks like for you?
Oh! Didn't answer. No. Let me try to explain:

Assuming that I did nothing - no DEFAULT.pif, no changes to apps.inf, no setting properties of any kind. Let's say I was showing the Desktop and started command.com for the Start Menu, it looks more as though the command prompt did open and then and went to a Window, like it should, but everything is wonky. I can tell that I'm looking at the desktop, but it's a jumble mess. I'd say you're theory though, could still be correct, it's just a different manifestation. I'm using Intel's Q963/965 video built-in to the Mobo.

User avatar
Steven W
VIP
Posts: 2893
Joined: 2013-08-10 22:40

2023-12-10 06:25 »

Steven W wrote:
2019-11-22 03:14
Running Win9x on real hardware or a virtual machine? Using VBEMP 9x as your video card driver and getting a corrupted screen when you bring up anything DOS-related? How would you like to have all DOS programs, files, et cetera go full screen? Well, here's how:
A word of warning:
Doing this likely will eliminate the ability to set properties on DOS files in Windows use a pif file, I theorize that adding a proper entry to apps.ini could overcome that shortcoming. I haven't tested that theory though.
Create a _DEFAULT.PIF
(text below is modified from Microsoft's Knowledge Base article Q131877):
  • Open the Windows folder.
  • On the File menu, point to New, then click Shortcut.
  • In the Command Line box, type "command.com" (without the quotation marks), then click Next.
  • In the "Select a name for the shortcut" box, type "_DEFAULT" (without the quotation marks), then click Finish.
  • Use the right mouse button to click the new _DEFAULT.PIF file, then click Properties on the menu that appears.
*Note: Make sure you have an underscore in front of the shortcut name, that's important! If you're showing extensions, you'll see that the new shortcut does NOT have an extension. That's the way you want it, but I'll keep referring to it as _DEFAULT.PIF for simplicity. As to those properties you want to set on your file:

set_properties.JPG
link to full-size image
  • On the Program tab, make sure the working field is empty
  • On the Screen tab, check the radio box Full-screen
  • On the Misc tab, uncheck the ALT+Enter shortcut key option (using this if enabled would allow the DOS program/utility/BAT... to minimize and cause the corruption we are trying to avoid)
  • Click Apply and OK
Set properties on command.com and the MS-DOS prompt shortcut:

*Note: the properties we're gonna set on these files are the same as we did on _DEFAULT.PIF above. Refer to the image if needed.
  • While you have the Windows folder open, right click on command.com and choose properties
  • On the Program tab, make sure the working field is empty
  • On the Screen tab, check the radio box Full-screen
  • On the Misc tab, uncheck the ALT+Enter shortcut key option (using this if enabled would allow the DOS program/utility/BAT... to minimize and cause the corruption we are trying to avoid)
  • Click Apply and OK
  • Click on the Start button, move mouse to Programs and right click on the MS-DOS Prompt shortcut, choose Properties (see note below if this does not work)
  • On the Program tab, make sure the working field is empty
  • On the Screen tab, check the radio box Full-screen
  • On the Misc tab, uncheck the ALT+Enter shortcut key option (using this if enabled would allow the DOS program/utility/BAT... to minimize and cause the corruption we are trying to avoid)
  • Click Apply and OK
  • Optionally (highly recommended), Use Windows Search function (Win key+F) to search for other instances of command.com and apply the same properties. Search in drive C:, make sure to look in sub-folders.
*Note: If you're using Windows 95 retail out of the box without installing Internet Explorer 4 or 5 (or chose not to install shell integration) or running a later version of 9x and have removed the shell integration, right clicking on the start menu does not work. You can get to the MS-DOS prompt shortcut in Windows Explorer by navigating to the proper folder, most likely 'C:\WINDOWS\Start Menu\Programs'.

Modify apps.inf:
  • Navigate to your INF folder, most likely C:\Windows\INF
  • Optionally (recommended), back up the file in that folder named 'apps.inf'
  • Double click on or right click - edit apps.inf. You'll get the message that the file is too big for Notepad, do you want to edit in Wordpad, choose yes.
  • Change the line that reads:
    COMMAND.COM=%COMMAND.COM%,pifmgr.dll,0,1,COMMAND.COM
    to read:
    COMMAND.COM=%COMMAND.COM%,pifmgr.dll,_DEFAULT.PIF,1,COMMAND.COM[
  • Save your changes
  • Reboot
Finishing up and dealing with it:

Once you've rebooted, Windows will build a driver information database. If you've done all of this correctly, any DOS program, BAT file, et cetera will run full screen. It can be a bit strange when in exe calls a BAT file and your screen goes blank for some time, but it'll eventually finish processing all it has to do and come back. You can use ALT+TAB to go back and forth between your DOS programs and Windows. If you need to open a DOS prompt and run some commands, just type 'exit' when finished.While it's probably best to use whatever 'exit' or 'close' mechanism your DOS program provides, however, if you absolutely must, you can ALT+TAB out of it and right click it in the Windows taskbar and close it that way. While this can seem like a pain, it's a heck of a lot better than have your screen corrupt and not knowing what the fuck you're looking at. I found myself adapting rather quickly and it's kinda fun playing DOS games full-screen. :wink:
I need to say a few things here, apparently. This is, at best, a somewhat ugly hack. I won't go so far as to say this couldn't 'work' with another video driver, but the odds are extremely slim. I wouldn't even try it unless the problems are pretty much exactly the same. The problem isn't limited to the command prompt, the whole screen fucks up/goes wonky/corrupts when you fire the command prompt up without this hack (a known problem with some video cards when using VBEMP 9x).

I probably won't explain all of this satisfactorily, but I guess I'll try. Creating the _default ('default.pif') file and setting it for fullscreen solves firing up the command prompt directly ONLY. If you double-click a DOS executable, a BAT file or anything that runs in the command prompt, you're stuck with that corruption again. Now, with that said, I think good ol' MS didn't realize when dishing out their advice in Q131877 (and probably elsewhere) that there's certain things/features/attributes that firing up command.com directly (not indirectly such as when double-clicking a DOS executable or BAT file...) without any 'fixes'. Most importantly, again when firing up command.com (without any 'fixes') there's NO FUCKING WORKING DIRECTORY set. Creating that DEFAULT.pif, in the manner that MS says to breaks some of those things/features/attributes because you're left with a set working directory. I describe one of those features as the command prompt's ability to 'follow you'. I'll try to explain that in greater detail if asked. I figured out the 'Working Directory thing' because of trying to run PC's SP3. You can imagine fairly easily, I think, that a batch file assuming that other files were in the same directory as itself didn't work when the working directory is set to something else. :lolno:

So, in order to solve the corruption when double-clicking a DOS executable, BAT file...I found that adding the line to apps.inf worked. That has some drawbacks. Let's look at what's supposed to happen with an unmodified apps.inf:

Code: Select all

COMMAND.COM=%COMMAND.COM%,pifmgr.dll,0,1,COMMAND.COM
the pifmgr.dll gets called to process any PIFs in the chain. Well, when you mod apps.inf as I changed it:

Code: Select all

COMMAND.COM=%COMMAND.COM%,pifmgr.dll,_DEFAULT.PIF,1,COMMAND.COM
pifmgr.dll is processing a PIF. Just not one 'in the chain'. It's pre-defined and always the same. While that works alright most of the time, at least as far as I can tell, it *could* be a problem when you *need* a PIF 'in the chain'. I was thinking of possible work-arounds for when someone absolutely need a PIF, you could mod the PIF to be fullscreen and add another line to apps.inf, perhaps, something along the lines of COMMAN2.COM=.... and add the name of the PIF file...,and just firing up COMMAN2, when needed, for example. Something else that gets broken too when applying my fix, look at all the entries in apps.inf. One of the points of that file was to solve issues with DOS compatibility on Windows with known 'problem children'. Some of those programs supposedly need to run in 'windowed mode' (not fullscreen). For the most part, I'd suggest DOSBox for the 'problem children' if you apply my ugly hack.

I hope that hell that makes sense to most of you.

User avatar
Steven W
VIP
Posts: 2893
Joined: 2013-08-10 22:40

2023-12-10 06:49 »

Heh, I guess, luckily *most of the time*, when running a DOS program, there ain't no PIF involved. :lol:

User avatar
Steven W
VIP
Posts: 2893
Joined: 2013-08-10 22:40

2023-12-10 15:02 »

Here, a bit of further reading for those who aren't familiar with why apps.inf exists on a 9x system:

https://jeffpar.github.io/kbarchive/kb/130/Q130971/

I also forgot to mention that I figured out why I had a command.com file in my root directory (C:\COMMAND.COM). I used a Win98 Emergency Boot Disk (although on a CD) to start setting up Windows 98SE. I had ran 'sys c:' to make the computer boot to a command prompt without the EBD. I then modded autoexec.bat and config.sys to load a CDROM driver so that I could run setup from the 98SE installation CDROM. Using 'sys c:' creates the file, among other things.

User avatar
Steven W
VIP
Posts: 2893
Joined: 2013-08-10 22:40

2023-12-13 03:27 »

One final thing, a quick and dirty test to see if this will work. Just create the _DEFAULT (aka default.pif) with Full-screen checkbox filled and either navigate to the Windows folder and double-click command.com or click the start button -- Run -- command (or command.com) if it comes up full-screen and doesn't mess, then proceed with the rest.

Post Reply