Results 1 to 3 of 3
  1. #1
    Star Lounger
    Join Date
    Feb 2003
    Location
    Hillsdale, New Jersey, USA
    Posts
    72
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Substitute Command

    I'm about to switch laptops from one that runs 98 to one that runs 2000. On the 98 machine I have a boot menu that allows me to choose between a configuration when I'm connected to my lan and one that I use when I'm travelling. I have programs and default file locations that all refer to my J: drive which is where I keep all my data. I use the DOS substitute command in my autoexec file in the non lan configuration (subst J: D. How can I do this in 2000?

  2. #2
    Uranium Lounger
    Join Date
    Jan 2001
    Location
    Cincinnati, Ohio, USA
    Posts
    7,089
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Substitute Command

    You can create a BAT file that will perform these steps and place it in the Startup folder of your 2000 system. In 2000, there is an AUTOEXEC.NT file that is run every time a command window is opened, but I believe you're wanting to perform this step automatically at logon, based on what you've posted. If you could include the logic from your AUTOEXEC.BAT it would be helpful, particularly if it includes some logic to detect the network drive and perform a conditional operation based on what that logic returns.
    -Mark

  3. #3
    Star Lounger
    Join Date
    Feb 2003
    Location
    Hillsdale, New Jersey, USA
    Posts
    72
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Substitute Command

    Thanks so much for the fast reply.

    To see what I'm doing in 98 here is my config.sys and autoexec.bat since they relate to each other:

    Config.sys
    ;config.sys. Boots either Docked Travel or Road Configurations
    [COMMON]
    rem not needed when windows runs DEVICE=COStoscdrom.sys
    DEVICE=c:windowsPanning.SYS


    [menu]
    Menuitem=Undocked_Subst,Undocked_Subst - AC Power Not Docked. J: Subst for D:
    Menuitem=AC_No_Subst,AC_No_Subst AC Power Not Docked J: Not subst for D:
    Menuitem=Battery,Battery - Battery Power Not Docked J: subst for D:
    Menuitem=Office,Office - AC Power Docked. Not subst J: for D:
    ;Menudefault=


    [global]
    DOS=HIGH,UMB
    DEVICE=C:WINDOWShimem.sys /testmemff /v
    FILESHIGH=100
    BUFFERSHIGH=20
    REM Remove the REM for the line below if needed for DOS memory
    rem DEVICE=C:WINDOWSEMM386.EXE X=D000-DFFF NOEMS
    rem Removed for new laptop shell=C:COMMAND.COM C: /e:512 /P


    [Undocked_Subst]
    include=global

    [AC_No_Subst]
    include=global

    [Battery]
    include=global

    [Office]
    include=global

    ***********************
    Autoexec.bat

    @ECHO OFF
    PATH=%PATH%;CCommand;DOS
    goto %config%
    :Undocked_Subst
    C:WINDOWSCOMMANDSubst J: D:
    goto Win98
    :AC_No_Subs
    goto Win98
    :Battery
    C:WINDOWSCOMMANDSubst J: D:
    goto Win98
    :Office
    goto Win98
    :Win98
    win

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •