Windows 7 Forums

Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: How to add a button to the context menu to copy a file to a directory

29 Apr 2014   #1
PSB

Windows 7 64 bit
 
 
How to add a button to the context menu to copy a file to a directory

Hi,
I use a few different files on a very regular basis. As an example, I have an Excel file that starts out as a template which I then modify to fit the situation. I start by navigating to the location of the "template" (via a shortcut to make it quicker), copying the file and then navigating to the sub directory where I need to copy the file. It's not a huge issue, but I'd love to simply navigate to the sub directory, right click my mouse to bring up the context menu and then click on a button to copy the file to the current sub directory I'm in.

I'm very close, but need help tweaking what I have. I created a bat file that I call from the Context menu (see below for the path I used). It works great, the only problem is that I have to click on a directory for my context button to come up. When I click on it copies my file, not into the directly I've selected, but into the current directory I'm in. This is actually good, because I'd like to be in the directory and then copy the file. The problem arises when I am in a directory that doesn't have a sub directory. In this case I have no directory to right click on and thus, I can't get my menu button to come up. I could go up one directory, click on the one I "really" want to work on, paste my file and then move the file, but I'm sure there is a better way.

Is there a location in registry where I can create a key that will come up when I right click my mouse and bring up the context menu my custom button will appear, allow me to run my bat file and copy my file into that active directory? Thanks in advance for any help with this question.


My current registry location:

HKEY_ROOT_CLASSES_ROOT
Directory
Shell
CostCalc (I created this)
Command (I created this and it calls my bat file)

My bat file:
rem file located in this location

Copy J:\work\ex_files\costcalc.xls


My System SpecsSystem Spec
.
29 Apr 2014   #2
Ztruker

Windows 10 Pro X64
 
 

Here are some instructions I've posted to add a batch file to the right click menu. It only appears when I click on a file within a folder as far as I can tell. You can replace my stuff with yours and see what happens.

Quote:
Add Is this a link to the Windows Explorer right click Context Menu.

Step 1:
Create isItaLink.bat.
Click Start, type notepad and press Enter.
Copy and paste the following RED lines into the Notepad window:

fsutil hardlink list %*
pause


Save the files as isItaLink.bat in a folder you will be keeping.

Step 2:
Create AddisLink.reg as follows:

Click Start, type notepad and press Enter.
Copy and paste the following RED lines into the Notepad window:

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\*\shell\isLink]
@="Is This a Link"

[HKEY_CLASSES_ROOT\*\shell\isLink\command]
@="\"C:\\
xxxxxxxx\\isItaLink.bat\" \"%1\""

Note: Change xxxxxxxx to the folder you put isItaLink.bat in.

Step 3:
Merge AddisLink.reg into you registry by double clicking on it or right clicking and select Merge.

To use, open Windows Explorer and navigate to the file you are interested in,
Right click on it and select Is This a Link.

A Command Prompt window will open with the results.
My System SpecsSystem Spec
30 Apr 2014   #3
SundRance

Windows 7 Pro 32bit / Windows 7 Ultimate x64
 
 

You might add the folder in question to your SendTo folder.

C:\Users\YOUR USER NAME\AppData\Roaming\Microsoft\Windows\SendTo

Navigate to the SendTo folder and create a new shortcut leading to your destination folder.

Be Well,
RȘnce

PS: I like to keep shortcuts to Notepad.exe and WordPad.exe in my SendTo folder as well, to quickly open files in those programs that are NOT normally associated with the text editors.
My System SpecsSystem Spec
.

30 Apr 2014   #4
PSB

Windows 7 64 bit
 
 

Thanks for both inputs. I used the suggested registry key location and it works great. Also, never knew you could modify the "Send To" folder. I'll definitely be using that trick!!
My System SpecsSystem Spec
18 May 2014   #5
PSB

Windows 7 64 bit
 
 

Hi,
I have been using these suggestions and most times they work GREAT! However, there are times when I start with an empty folder. I doubt that I can add a shortcut to my bat files directly in the context menu that comes up when you hit the right mouse button in an empty folder. There is a sub menu entitled "NEW" that appears to be editable. Can anyone tell me if I can add my bat file short cuts to this sub menu and if so the path to its location in the registry. Thanks so much
My System SpecsSystem Spec
Reply

 How to add a button to the context menu to copy a file to a directory




Thread Tools Search this Thread
Search this Thread:

Advanced Search




Similar help and support threads
Thread Forum
directory shell context menu item to rename file extensions
I have used the following registry mod successfully in win XP to add a right click option on a folder to rename m4a (AAC files) to m4b (bookmarked AAC files). Windows Registry Editor Version 5.00 @="Rename m4a to m4b extensions" @="cmd.exe /c \"rename *.m4a *.m4b\""
General Discussion
add, or replace copy, cut, paste with robocopy in context menu?
I heard robocopy/fastcopy/richcopy is much faster due to multi threaded (high queue depth) copying so I wanted to give it a try. thing is going through cmd typing all folder directories as well as at times unable to type everything due to Chinese and Korean characters in a lot of my...
Customization
Copy Content to Clipboard - Add to Context Menu
How to Add "Copy Content to Clipboard" to Context Menu in Vista, Windows 7, and Windows 8 This tutorial will show you how to add or remove Copy to Clipboard from the right context menu of BAT, CMD, CSS, HTML, JS, LOG (txt), REG, RTF, TXT, and VBS files in Vista, Windows 7, and Windows 8. ...
Tutorials
Remove Userfolder and desktop from Copy to Move to context menu
Can i possibly remove this things? http://img13.imageshack.us/img13/3775/captureedh.png Uploaded with ImageShack.us
Customization
How to Customize the Start Button right click context menu
How to Customize the Start Button right click context menu? I've used custom Registry entries since Windows 95 to add several stock programs to the right click context menu for the Start button. In Windows 7 Pro - right click on the Start button to see a context menu: Two options...
Customization
How to remove Cut, Copy & Paste options from context menu?
Hi all, I think the subject above says, it all. I'd like to remove the Cut, Copy and Paste options from the context menu because I use shortcut keys for them + Delete too, like in the attachment, but applicable in all uses. Is it possible? Thanks! MrGreggles
Customization


Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd

All times are GMT -5. The time now is 21:24.

Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App