MioKawaii Posted April 23, 2006 Share Posted April 23, 2006 I'm trying to use a CMD to do things when I right click on a file but how to get the filename of the file that I click on?eg: - I put a utility name base64.exe in windows\system32- I right click on a file name 01.base64 reside in any folder and choose "Base64 Decode" (which is done through registry entry below)HKLM, "%CLASS%\.Base64\shell\Base64Dec", , , "Base64 Decode"HKLM, "%CLASS%\.Base64\shell\Base64Dec\command", , , "base64.cmd"The base64.cmd contains the following code:@echo off:BaseDecMode 80,12 & Color f1ECHO Please input the desire new output filename including the extention.SET NewName=SET /P NewName=Please input the desire new output filename including the extention.base64 -d "%1" "%NewName%"EXIT:Base64Enbase64 -e "%1" "%1.Base62"EXITAs you all can see, the %1 does not work here. Please help! Link to comment Share on other sites More sharing options...
RogueSpear Posted April 23, 2006 Share Posted April 23, 2006 HKLM, "%CLASS%\.Base64\shell\Base64Dec", , , "Base64 Decode"HKLM, "%CLASS%\.Base64\shell\Base64Dec\command", , , "base64.cmd"I may have the syntax off slightly but perhaps you need a %1 in there:HKLM, "%CLASS%\.Base64\shell\Base64Dec", , , "Base64 Decode"HKLM, "%CLASS%\.Base64\shell\Base64Dec\command", , , "base64.cmd %1" Link to comment Share on other sites More sharing options...
MioKawaii Posted April 24, 2006 Author Share Posted April 24, 2006 Thanks! But how do I go to a certain LABEL in this base64.cmd file from the registry? Link to comment Share on other sites More sharing options...
RogueSpear Posted April 24, 2006 Share Posted April 24, 2006 I'm guessing that you'll need to create more logic in your batch file for it to do what you want it to do. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now