7zip timestamp archive under context menu - windows-vista

Does anyone know how I can add a context menu item that would compress a folder and add a timestamp? So that I can right-click a folder and it would give me the option to create something like this: folder_20100528.zip
(I'm posting it here because I figure it's something that's done through a batch file/code)

The batch script should be reasonably simple, so create it and throw it in C:\
On XP:
Then open explorer and click the 'Tools' -> 'Folder Options' menu.
Select the 'File Types' tab.
Scroll down the extensions list until you find 'File Folder', and highlight it.
Click the 'Advanced' Button
This will open a new window, where you can create 'actions' (eg context menu items).
Simply make a new one, call it what you want, and set up the parameters to send into the batch file.

the batch script is what I was trying to figure out ; )
SET ZIPPATH="C:\Program Files\7-Zip\7z.exe"
SET TIMESTAMP=%date:~6,4%%date:~3,2%%date:~0,2%-%Time:~0,2%%Time:~3,2%
%ZIPPATH% a -tzip "YRH_%TIMESTAMP%" "YRH\*"
for now I'm just using a .bat file that I dropped in the directory, I'll try to implement the rest later
thanks

Related

insert an item in the menu context of any text editor (on windows)

I want to simplify a process by right-clicking in a text editor. this item launchs a *.bat file.
I have searched in the registry editor. I know how create the keys, but I know where create them to add this action after the famous "cut, copy, paste, ..."
by advance thank you.
CudaText editor (free) has this feature via Configure Menu plugin. You run the plugin, create the menu JSON file, then edit this file, to add any command.
How to add command for Bat file? Via plugin External Tools. Add there command to call bat file.

How do I change the 'New File' destination in Xcode?

Everytime I click 'New File' in Xcode, it opens a Finder window with the project folder. I want to change the default 'New File' destination to some arbitrary folder.
How can I do this?
Edit: When I say 'New File', I am referring to File > New > File
You can't.
You will always have to navigate to the parent folder you want the new file to appear in.
You can, however, ensure the new file gets added to the correct Group within Xcode by selecting the Group (left click) and then selecting New File... from the context menu (right click).
I think this is a missing usability feature as Xcode should map Groups to filesystem Folders where ever possible.

Add an action combo to right click menu on any FILE

I want to add a combo of actions to right click menu for any file. Lets say I have files on \fileserver\file.exe; word.doc; text.txt...... I would like to have an option to copy that .exe file to local c:\test folder and then open that word.doc file when I right click on that .exe file.
What option do I have to perform this? Regedit? or third party tools?
I found some third party tools that can modify right click menu, but they can't add new functions into it.
Any idea?

SHBrowseForFolder text edit

I have some questions regarding SHBrowseForFolder(). I am using it with BIF_USENEWUI, BIF_RETURNONLYFSDIRS and BIF_VALIDATE. I am mainly having problems with the edit box. I'd like it to function a bit differently.
Let us assume, I am at a valid directory "C:\path". If I type in a non-existing folder (Let us call it "Folder1") into the textbox and then press OK, then the path I receive is "C:\path". Is there a way to have it so that when I press OK, it creates "Folder1" in "C:\path" and gives me the path "C:\path\Folder1"? (Without having to use the Make New Folder button)
Currently, I can click on "Make New Folder", which creates a new folder that I can rename. In the text edit, it appears as New Folder (its default name). After I rename the folder, it still appears as New Folder in the text edit, unless I click on another folder and then click back on the newly named folder. Is there a way for the text edit to be updated as soon as I rename the folder?
1 install an application-defined callback function and specify the BIF_VALIDATE flag, then handle BFFM_VALIDATEFAILED and try to create the folder there.
2 you can subclass the dialog and the text edit in BFFM_INITIALIZED and look for TVN_BEGINLABELEDIT and TVN_ENDLABELEDIT from the tree control, then change the text in the edit control based on the change to tree node text when the user finishes editing. The dialog id for controls on the browse folder dialog is not documented, so there is a compatibility risk you need to consider. I won't be surprised if your code breaks after a Windows update/upgrade, but as a user, this is not a feature I would miss anyway.

Explore containing folder instead of open containing folder

I use Visual Studio to do a lot of my coding. I find the open containing folder feature quite helpful. But I don't want the folder to be "opened" by the windows explorer, instead I want to "explore" the folder -- you know, get the nice little frame showing me all the other folders on the left hand side. Does anyone know how to do this?
Thank you,
Rohit
When invoking ShellExecute(), use the explore verb instead of the open verb: http://msdn.microsoft.com/en-us/library/bb762153%28VS.85%29.aspx.
Edit: If you don't mean programmatically, open Windows Explorer, go to Tools -> Folder Options, select the File Types tab, locate the Folder entry in the list (not File Folder!), click Advanced, and set "explore" as default instead of "open".
There really isn't much difference anymore between 'explore' and 'open' if you're talking about a folder. They both open the same window, just with different options active. When you 'open' the folder, you're only one click away (on my system at least) from seeing the folder tree as well- just click the "Folders" button in the toolbar.

Resources