In XP, you can quickly copy the complete path of a file to the clipboard as in Vista.

Source: Internet
Author: User
In XP, you can quickly copy the complete path of a file to the clipboard as in Vista. In Windows XP, you can drag and drop files.But in Vista, I found a disgusting "new feature", which is actually removed. If you want to obtain the complete path of a file, you must manually copy the file name through "RENAME", and then get the address bar to work together with that path, if it is a long file name, you must add a "symbol to both the left and right, which is really annoying ......

However, I believe Microsoft will not be so shameless, So Google found many posts that complained like me, and only from those posts found that there was actually a hidden command, you can easily copy the complete path of a file to the clipboard, which makes up for the defect that you cannot drag the file to cmd.

The operation is simple: press shift first, and then right-click a file, there will be an"Copy to path". In this way, you can copy the complete text of the file.

=============================== Boring split line ========================== ===

Then Baidu went down, and the articles that introduced this technique were rampant. Ah, shame. If you do not find any more "copy as path" in your right-click menu, what is your system? I am talking about Vista ~~~~~ (Have you followed the operation in XP? ^ _!)

However, I think this feature is also needed when I use XP many times, so I also found a simple implementation method on Google. Original article: http://www.winhelponline.com/blog/add-copy-as-path-option-to-the-context-menu-in-windows-xp/

First, download a Microsoft applet (less than 6 K) ftp://ftp.microsoft.com/Services/TechNet/samples/PS/Win98/Reskit/FILE/CLIP.EXE

Http://xiazai.jb51.net/201101/tools/clip.rar

Second, save the following content as copypath. vbs

Http://www.winhelponline.com/blog/wp-content/uploads/copypath.vbs

ASP/Visual Basic Code
  1. '""""""""""""""""""""""""""""""""""""""" """""""""""""""""""""""""""""""""""""""" """"
  2. 'Copyright notice: This script and all material at winhelponline.com are registered
  3. 'With "the UK Copyright service". no part of the website can be distributed or...
  4. 'Republished without the author's written permission.
  5. 'Copyright? 2008 by Ramesh srinloud. All rights reserved.
  6. '""""""""""""""""""""""""""""""""""""""" """""""""""""""""""""""""""""""""""""""" """"
  7. 'Copypath. vbs-file description
  8. '""""""""""""""""""""""""""""""""""""""" """""""""""""""""""""""""""""""""""""""" """"
  9. 'Copy the path of a file or folder to the clipboard
  10. 'Created on May 10,200 8
  11. 'Copyright? 2008 Ramesh srin.pdf.
  12. 'Author: Ramesh srinence, Microsoft MVP (Windows desktop experience)
  13. 'Website: http://www.winhelponline.com
  14. '""""""""""""""""""""""""""""""""""""""" """""""""""""""""""""""""""""""""""""""" """"
  15. Set wshshell = wscript. Createobject ("wscript. Shell ")
  16. Strmsg = "completed! "& CHR (10) & CHR (10) &" copypath. vbs -? 2008 Ramesh srinesh "& CHR (10) & CHR (10) &" visit us at http://www.winhelponline.com/blog"
  17. Strbasebrch = "HKLM \ SOFTWARE \ Classes \"
  18. If wscript. Arguments. Count <> 0 then
  19. Wshshell. Run "% comspec %/C" & "Echo" & CHR (34 )&_
  20. Wscript. Arguments. Item (0) & CHR (34) & "| clip.exe", 0
  21. Else
  22. RTN = trim (ucase (inputbox ("type install to add the copy as path context menu option, or type uninstall if you wish to remove the context menu option from your system. "," processing ing copypath. vbs... "," Install ")))
  23. If RTN = "Install" then runinstall
  24. If RTN = "Uninstall" then rununinstall
  25. End if
  26. Sub runinstall
  27. 'Add registry values
  28. On Error resume next
  29. Strcmd = "wscript.exe % SystemRoot % \ copypath. vbs" & CHR (34) & "% 1" & CHR (34)
  30. Wshshell. regwrite strbasebrch & "allfilesystemobjects \ shell \ copypath \", "copy as path", "REG_SZ"
  31. Wshshell. regwrite strbasebrch & "allfilesystemobjects \ shell \ copypath \ extended", "", "REG_SZ"
  32. Wshshell. regwrite strbasebrch & "allfilesystemobjects \ shell \ copypath \ command \", strcmd, "reg_expand_sz"
  33. On Error goto 0
  34. Msgbox strmsg, vbokonly, "installed"
  35. End sub
  36. Sub rununinstall
  37. 'Remove the registry values added by this script.
  38. On Error resume next
  39. Wshshell. regdelete strbasebrch & "allfilesystemobjects \ shell \ copypath \ command \"
  40. Wshshell. regdelete strbasebrch & "allfilesystemobjects \ shell \ copypath \"
  41. On Error goto 0
  42. Msgbox strmsg, vbokonly, "uninstalled"
  43. End sub
  44. '""""""""""""""""""""""""""""""""""""""" """""""""""""""""""""""""""""""""""""""" """""""""""
  45. 'This script was brought to you by "The winhelponline blog"
  46. 'Visit us at http://www.winhelponline.com/blog
  47. '""""""""""""""""""""""""""""""""""""""" """""""""""""""""""""""""""""""""""""""" """""""""""

Third, put the above two files, copypath. vbs and clip. EXE, under the C: \ Windows directory, and double-click copypath. vbs to confirm.

OK. Now, when you try to hold down SHIFT and Right-click a file, is there a "copy as path" in the menu?

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.