The moderator's msdos710 boot disk is very useful, but if you want to run Windows 98 on the hard disk, you need to manually enter the Windows 98 installation path and run it. The little girl wrote a batch program of ndos to automatically call Windows 98 on the hard disk.
The working principle is as follows: The program first finds c:\msdos.sys, then checks each line of text in the msdos.sys file one by one in a loop. If the "WinDir=" statement is found, it is set as a variable and the loop is exited. According to the corresponding value of windir, the installation path of Windows 98 is found and Windows 98 is run.
Here, I'm just putting forward a simple idea, hoping that everyone will work hard. This program can also use xset instead of ndos to complete.
The following are several internal functions of ndos involved:
%@lines Used to return the number of lines of the file
%@line Used to return the content of the specified line of the file
%@len Used to return the length of the string
%@eval Used to return the result of +-*/ operations
%@substr Used to return n characters starting from the starting position of the string
%variable name% Returns the content of the variable
To run in the msdos710 environment, you can enter "ndos /c loadwin" to run
The content of the loadwin.bat program is as follows:
*********************************************
@echo off
setlocal
if not exist c:\msdos.sys goto error
set x=%@lines
set y=0
:loop
set winx1=%@line
if %y%*==%x%* goto error
set l=%@eval-7]
set winx=%@substr
if #%winx%#==#WinDir# goto setdir
set y=%@eval
goto loop
:setdir
set winx2=%@substr
set winx3=%@substr
%winx3%
cd %winx2%
path %winx2%;%winx2%\command
set x=
set y=
set l=
set winx1=
set winx2=
set winx3=
set winx=
WIN /D:N
:error
echo ERROR ! windows_9x_Path unknowed !!!
echo 1.THERE IS NOT C:\MSDOS.SYS!
ECHO 2.C:\MSDOS.SYS can not load Windows9x!
ECHO Press any key to continue!
PAUSE>NUL
goto end
:end
endlocal
quit
***************************************************
The working principle is as follows: The program first finds c:\msdos.sys, then checks each line of text in the msdos.sys file one by one in a loop. If the "WinDir=" statement is found, it is set as a variable and the loop is exited. According to the corresponding value of windir, the installation path of Windows 98 is found and Windows 98 is run.
Here, I'm just putting forward a simple idea, hoping that everyone will work hard. This program can also use xset instead of ndos to complete.
The following are several internal functions of ndos involved:
%@lines Used to return the number of lines of the file
%@line Used to return the content of the specified line of the file
%@len Used to return the length of the string
%@eval Used to return the result of +-*/ operations
%@substr Used to return n characters starting from the starting position of the string
%variable name% Returns the content of the variable
To run in the msdos710 environment, you can enter "ndos /c loadwin" to run
The content of the loadwin.bat program is as follows:
*********************************************
@echo off
setlocal
if not exist c:\msdos.sys goto error
set x=%@lines
set y=0
:loop
set winx1=%@line
if %y%*==%x%* goto error
set l=%@eval-7]
set winx=%@substr
if #%winx%#==#WinDir# goto setdir
set y=%@eval
goto loop
:setdir
set winx2=%@substr
set winx3=%@substr
%winx3%
cd %winx2%
path %winx2%;%winx2%\command
set x=
set y=
set l=
set winx1=
set winx2=
set winx3=
set winx=
WIN /D:N
:error
echo ERROR ! windows_9x_Path unknowed !!!
echo 1.THERE IS NOT C:\MSDOS.SYS!
ECHO 2.C:\MSDOS.SYS can not load Windows9x!
ECHO Press any key to continue!
PAUSE>NUL
goto end
:end
endlocal
quit
***************************************************
我是女孩,我怕谁?





