Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

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++
share|improve this question

migrated from stackoverflow.com Apr 18 '11 at 9:26

This question came from our site for professional and enthusiast programmers.

3 Answers 3

up vote 3 down vote accepted

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.

share|improve this answer
    
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 '11 at 8:04
explorer .

That answers your first question.

share|improve this answer

Alternatively, you can use the shorter command

start .
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.