2

You open cmd and type (for example) cd C:\dragons

How can you open C:\dragons in the file explorer? Yes, you can use explorer C:\dragons, but that is kinda lame. Let's say I'm in the folder C:\dragons\Red\WhiteCrests\infants, this way just isn't convenient.

Already tried explorer dir and explorer path (both of which opens My Documents for some reason), just explorer (opens the Libraries folder), open which is undefined, explorer dirname which gives me that dirname is undefined, and probably other stuff that I can't remember.

Thanks in advance.

...Shamelessly adding to the question with a thought I just had, how can you open a file (say C:\dragons\intro.txt) with a specified program? Like, instead of the default one (like Notepad), open it in Notepad++, without using Notepad++'s (if one exists) command line stuff. Something like:

cd C:\dragons
intro.txt --Notepad++
0

3 Answers 3

6

explorer . will open an Explorer point to the current directory.

notepad intro.txt will open it in Notepad (gotta have it in PATH; Notepad you probably do already). Same thing goes for Notepad++, put it in PATH and (maybe rename it to something more pleasing) and use Npp intro.txt.

1
  • If Notepad++ is the default application to edit a text file with then it's sufficient to use start in both cases, even.
    – Joey
    Apr 18, 2011 at 8:04
6
explorer .

That answers your first question.

0
3

Alternatively, you can use the shorter command

start .

Not the answer you're looking for? Browse other questions tagged .