Computing.Net > Forums > Disk Operating System > Second command enviroment in MSDOS

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

Second command enviroment in MSDOS

Reply to Message Icon

Name: Mac
Date: July 31, 2002 at 01:58:59 Pacific
Comment:

Hi

I am having a few problems with a secondary command enviroment that is opened in MSDOS. These problems are:
When the command launching the secondary enviroment executes in the AUTOEXEC.BAT the remaining section of the AUTOEXEC.BAT is not completed. This is due to the launching of the new enviroment. Also, all evniromental settings are lost due to this.
What I need to know is how to complete the AUTOEXEC.BAT or start a new batch file in the secondary enviroment that can complete what was to be done in AUTOEXEC.BAT. Needless to say this need to be done automatically since the option to boot with is labled Autostart.

Thanks



Sponsored Link
Ads by Google

Response Number 1
Name: Doug
Date: July 31, 2002 at 06:48:19 Pacific
Reply:

If you are calling batch files from within batch files, do NOT simply execute the second batch file, use the CALL function instead.

example:

loadhigh c:\dos\doskey.com
loadhigh c:\dos\mouse.com

call macros.bat

mem
ver

Where macros.bat is a batch file which contains a list of aliases. The file called does not have to be a batch file, it can be any executable file, I believe.

You shouldn't be using command.com in your AUTOEXEC.BAT.

If you are trying to increase the environment size, or tell your OS to use a different command interpreter after booting, use the following in your CONFIG.SYS:

SHELL=c:\dos\command.com /e:8192 /p

/e:WXYZ, environment variable size, in bytes.
/p makes command interpreter permanent. (an EXIT command will not end the current session)

-Doug


0

Response Number 2
Name: Mac
Date: August 1, 2002 at 02:46:21 Pacific
Reply:

Hi

Ok, let me go into a little more detail. I am using NTFSPro for DOS. It has 2 options. One uses all extended ram to load. Needless to say DOS software will have issues with DPMI (errors like Not enough DPMI ram). The second option is that a DOS/4GW version is used. The only problem is that this version wasnt as part of the command line a location for COMMAND.COM. Once NTFSPro loads, it loads the new command enviroment. There goes anuthing from the previous enviroment. I have looked at the Knowledge Base for the product, and there is no answer for this.

Also, what I was wondering. If I were to remove the /P option in the Config.Sys Shell=Command.com line, will the loading of a new Command.com load "update" the Command enviroment loaded by Config.sys?

Thanks for the help so far.

Mac


0

Response Number 3
Name: Doug Stoffa
Date: August 1, 2002 at 08:13:10 Pacific
Reply:

Using the SHELL= command in your config.sys with the /p switch file is usually used to increase the environment variable size. It is also used to specify a location for the OS to find the command interpreter if it's not located in the root directory of the disk which was booted from.

The first shell is ALWAYS permanent. Any shells invoked after the first simply sit ontop of the permanent one. Environment conditions and variables (PATH, etc.) are NOT passed from shell to shell in DOS. (I am not sure if there is an EXPORT command in DOS.)

Removing the /p switch will not help you.

How does your software start? What commands are required to invoke it? If it's a batch file, you may be able to edit it such that it will not invoke it's own command interpreter for the duration of its execution. If it is an executable file, you may be out of luck. If it's a .com file, you may try to say that SHELL=c:\"your .com file here".

You have nothing to lose by trying.

Use F5, F8, or F9 (I don't remember which) to prevent DOS from using your config.sys and autoexec.bat when booting (when you see Starting MS-DOS) in case the above modifications don't work. (You will bypass the files, and be able to undo your changes.)


0

Response Number 4
Name: Mac
Date: August 2, 2002 at 08:02:59 Pacific
Reply:

Thanks. I guess I am out of luck then. It was worth a try to ask. I to have not yet seen an Export command for DOS. This would be very useful.
The program is an executable. All I did was add its full command line, as needed to run, into the Autoexec.bat. Oh, well, I do have a backup option. It will require the user to type a few letters and hit enter. That is, I just create a batch file with the necessary commands in to complete the boot sequence and warn the user from the Autoexec.bat that the will need to type the batch command.

Again thanks.

Mac


0

Response Number 5
Name: Doug
Date: August 2, 2002 at 12:08:27 Pacific
Reply:

Did you try inserting:

call 'my full command line as needed to run here'

in your autoexec.bat?

-Doug


0

Related Posts

See More



Sponsored Link
Ads by Google
Reply to Message Icon

Unique .Com file request vga driver is not istalli...



Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Disk Operating System Forum Home


Sponsored links

Ads by Google


Results for: Second command enviroment in MSDOS

I can't dial in MSDOS www.computing.net/answers/dos/i-cant-dial-in-msdos/4393.html

calling dialupnetworking in msdos. www.computing.net/answers/dos/calling-dialupnetworking-in-msdos/2976.html

startup menu in msdos 7.10 www.computing.net/answers/dos/startup-menu-in-msdos-710/15916.html