Monday, February 04, 2019

After 20+ years in IT .. I finally discovered this...

Originally I was not going to write this post, but after I found out that several other people didn't know this I figured what the heck, why not, maybe this will help someone else as well

Last week I was on a remote session with 2 clients, each run the Advent program . The team I am part of provides a script to run the advent (APX or Axys) executable. This will then generate the portfolios, composites, price, security master, splits and other files. We then zip it up and sftp it over for ingestion so that we can run analytics and attribution

During these calls I interact with system administrators because usually the need to give permissions so that the script runs correctly

None of these admins knew that what I will show you existed. All the co-workers I asked didn't know this either (This could be because they are developers and not admins)



Back in the day (win 98 or perhaps NT 4), there was a windows powertool that you could install and if you right clicked on a folder you would get an option to open a command window and it would be in the path that you right clicked on

Those power tools don't exist anymore and you could do the same by hacking the registry, it's like a 16 step process

But there is a faster way.....

So what I usually did before 2 months ago is that I would select the path


And then I would open a command prompt, type CD and then paste the path...not too complicated

But here is the faster way.... instead of copying the path...just type in cmd in the address bar and hit enter


Boom shakalaka... a command prompt is opened immediately and you are in the same path



Did you know this also works when you type Powershell in the address bar, Eric Darling left me a comment on twitter informing me that it works with powershell as well

Here is what you see after typing it




So there you have it... hopefully it will save you some minutes of valuable time in a year

Also if you knew about this or did not know..leave a comment and let me know





33 comments:

  1. Huh, pretty cool. I just tried it in Windows 7 and it works like a charm.

    I also know that if you shift-right-click on a folder, there's an option for "Open command window here" but I like this solution better.

    ReplyDelete
  2. Anonymous7:30 AM

    That's pretty cool - but as often as not I want to open a Command Prompt window as/in Administrator mode. I wonder if there's a quick way to do that using this method?

    ReplyDelete
  3. George7:37 AM

    didn't know that! brilliant! thanks for sharing :)

    ReplyDelete
  4. I did not know about it, very nice, thank you.

    ReplyDelete
  5. I always remember this method right after performing the copy+paste method. *doh*

    ReplyDelete
  6. Did you know you can also drag any file or folder onto the CMD window to paste its complete path?

    ReplyDelete
  7. Didn't know :-D Thankyou

    ReplyDelete
  8. Didn't know this before

    ReplyDelete
  9. Thank you for sharing this awesome shortcut.

    ReplyDelete
  10. Very useful. Great post

    ReplyDelete
  11. And there's another tip, the other way around:
    From cmd, when you're in the desired directory, run the following command to open that dieectory in explorer:
    Explorer .

    ReplyDelete
  12. Very cool! I knew about the option to invoke command prompt by right clicking on the folder node on Windows Explorer. But this is even better! Thanks for sharing.

    ReplyDelete
  13. Already knew it 👍

    ReplyDelete
  14. Great, I will try this trick!
    If you want do it in reverse you can print in CMD:
    Start.
    It will open a window from the place you are in.

    ReplyDelete
  15. Branden12:08 PM

    Also, if you hold SHIFT and RIGHT CLICK in the folder, there will be an option to "Open command window here". In newer versions of windows, it changed from command window to powershell.

    ReplyDelete
  16. Yeah it’s a nice trick, but as a admin to access that folder with my domain admin account i need run as different user or I need to run cmd/powershell over UAC

    ReplyDelete
  17. Anyway to open in admin mode?

    ReplyDelete
  18. Anonymous12:51 PM

    It doesn't work for absolute network share paths. CMD states unknown UNC. Shift + Right click > open Cmd.. actually figured out the network mount drive letter, but CMD in address bar is no bueno. Win7 pro

    ReplyDelete
  19. To open a an admin cmd

    cmd runas /user:Administrator

    works for me on win7 but on win 10 it opens a regular command window

    ReplyDelete
  20. Also you can do the reverse if you Invoke-Item from powershell. `ii .` works wonders.

    ReplyDelete
  21. Tried it on my first window open and didn't work, guess it doesn't work on mapped or network drives

    ReplyDelete
  22. Very cool, thanks for sharing! Powershell works too by typing powershell. However, I couldn't load it as an administrator..

    ReplyDelete
  23. Veey cool. Didn't know. Thought I knew everything.

    ReplyDelete
  24. you can also do (shift)+(right click) to open powershell.

    ReplyDelete
  25. And I always thought we are the only team in the world using Axys for Portfolio reporting :P

    ReplyDelete
  26. Anonymous8:52 PM

    Very nice ��. The open command prompt here hack is still available as registry files to install or uninstall.

    ReplyDelete
  27. Anonymous1:31 AM

    Thank you very much! I didn't know this. Very Nice!

    ReplyDelete
  28. You could also drag the folder in your cmd

    ReplyDelete
  29. Yes that’s is one of the shortcut to open the path to from windows rather than typing in command but not offending this but it’s nothing new in it.

    ReplyDelete
  30. Type notepad.exe in the adresbar and it opens as well.

    ReplyDelete
  31. I've used this trick for a few years now. I love my shortcuts, I use alt+d to highlight the address bar and then type cmd/powershell.

    ReplyDelete