WinBatch Tech Support Home

Database Search

If you can't find the information using the categories below, post a question over in our WinBatch Tech Support Forum.

TechHome

How To
plus
plus
plus
plus
plus
plus
plus
plus
plus
plus
plus

Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.

Create a Template WBT file


Question:

I was wondering if there was a way to use a template WBT file somehow when creating new winbatch files. I am trying to keep my code in a certain format and layout, and currently copy a template wbt file to do that (when I remember). I was wondering if there was any way to have the default wbt file be my template so I don't have to manually remember to do this every time. For example when I right click in a folder and select New | Winbatch file, it would create a new file with my template instead.

Answer:

Ummm. Yes, kinda. We don't actually support it, but the idea is that there are some registry entires what control all that.

Create the template WBT file and place it in the "ShellNew" directory under your Windows directory. Then run this script to make the necessary registry entry (assuming the file name is "template.wbt"):

RegSetValue(@REGCLASSES, ".WBT\ShellNew[FileName]", "template.wbt")

Article ID:   W15966
File Created: 2004:03:30:15:42:04
Last Updated: 2004:03:30:15:42:04