topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • Thursday March 28, 2024, 5:29 am
  • Proudly celebrating 15+ years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Author Topic: 2 launches: task manager, DOS prompt with directory  (Read 8943 times)

ottenm

  • Supporting Member
  • Joined in 2008
  • **
  • default avatar
  • Posts: 93
    • View Profile
    • Donate to Member
2 launches: task manager, DOS prompt with directory
« on: February 28, 2008, 08:36 PM »
Subject says it all, I just can't find either of them.  I can get DOS launched with an alias set to "cmd", but I'd like it to open in a different directory (not farr's).


mouser

  • First Author
  • Administrator
  • Joined in 2005
  • *****
  • Posts: 40,896
    • View Profile
    • Mouser's Software Zone on DonationCoder.com
    • Read more about this member.
    • Donate to Member
Re: 2 launches: task manager, DOS prompt with directory
« Reply #1 on: February 28, 2008, 09:01 PM »
very good idea -- does anyone know is there an easy way to open a commandline in a specific directory, or do i need to add a general purpose ability to change to a specific directory when specifying an alias?

jgpaiva

  • Global Moderator
  • Joined in 2006
  • *****
  • Posts: 4,727
    • View Profile
    • Donate to Member
Re: 2 launches: task manager, DOS prompt with directory
« Reply #2 on: February 29, 2008, 05:11 AM »
About the commandline, that's simple. Just create a new alias and add the following as a result:

cmd /k DRIVE: && cd FOLDER

Replacing DRIVE and FOLDER with the appropriate content.

ottenm

  • Supporting Member
  • Joined in 2008
  • **
  • default avatar
  • Posts: 93
    • View Profile
    • Donate to Member
Re: 2 launches: task manager, DOS prompt with directory
« Reply #3 on: February 29, 2008, 07:00 PM »
Not having any luck.  Have tried many variations, even trimming them to just:
cmd /k D:  // thinking it would open cmd pointing to D:
and
cmd && dir // thinking it would open and run/display a dir

But nothing works, no cmd prompt even opens.  It does work with just "cmd" as the result, but points to the FARR directory.

jgpaiva

  • Global Moderator
  • Joined in 2006
  • *****
  • Posts: 4,727
    • View Profile
    • Donate to Member
Re: 2 launches: task manager, DOS prompt with directory
« Reply #4 on: February 29, 2008, 07:26 PM »
Ok, i didn't test that, but now i tested something that works:
"C:\WINDOWS\system32\cmd.exe /k d:\ && cd FOLDER"
Should be a solution. For some reason, the collons are necessary.

ottenm

  • Supporting Member
  • Joined in 2008
  • **
  • default avatar
  • Posts: 93
    • View Profile
    • Donate to Member
Re: 2 launches: task manager, DOS prompt with directory
« Reply #5 on: March 01, 2008, 07:09 AM »
Perfect!  Thanks jgpaiva, without the double quotes, here's what worked for me:

C:\WINDOWS\system32\cmd.exe /k c: && cd MyFiles

jgpaiva

  • Global Moderator
  • Joined in 2006
  • *****
  • Posts: 4,727
    • View Profile
    • Donate to Member
Re: 2 launches: task manager, DOS prompt with directory
« Reply #6 on: March 01, 2008, 05:55 PM »
Great ottemn, glad to know that :)