Allow batch file Minimize DOS window?

So I'm a little in MS-DOS and again, but I came to ask myself: How can I minimize the DOS window? Any view will be in order, minimized, compressed to a tiny blue block.

I just can’t find a way to make it work on my computer running Windows XP, is it really ruled out in XP ?!

+3
source share
3 answers

One thing you could do is create a Windows program that will find the title bar of the cmd window you are working in, and minimize it in that program. In Win32, you should use the FindWindow command to get the window handle, then CloseWindow to minimize it. Something like this completely untested program:

int main(int argc, char** argv)
{
    HWND wnd = FindWindow(      
        NULL,
        argv[1]
        );
    CloseWindow(wnd);
    return 0;
} 

In the cmd window, you can set the title for a specific line (to avoid ambiguities), and then pass this name to the program in your program:

C:\>title TitleOfWindowToMiniMize

C:\>minimizeWindow TitleOfWindowToMiniMize
+5
source

You can run the program in a new minimized window using the command start:

start /min your_command_here
+6
source

. DOS. DOS .

In Windows, you can write a small program that will look for your window and send it a corresponding message, which will minimize it. Similarly, you can maximize or hide / show your window.

+1
source

Source: https://habr.com/ru/post/1706865/


All Articles