home / experts / javascript / column56 |
|
Template-Saving ExampleIn this example we create a new template-saving file dialog. HoTMetaL comes with several templates you can choose from. A template is just an ordinary Web page that is stored in a folder underneath the You create a new template by saving the current document into a folder underneath the
We first create an ActiveX control out of the FileDlg COM object of HMExtras library:
We then create a filter with several entries:
We display the file dialog by calling Let's add first the Save As Template macro to the File menu. Right click on the File menu bar and select customization. Choose the Menu tab and navigate to where you want to add the new macro. Click on the Add Submenu button and fill out the missing items. Here is the dialog:
Let's test now how this menu item and macro work. Pull down the File menu. You can see the new Save Template entry. Click it. You get the following dialog:
Feel free to navigate to the desired folder and hit the Save button. |
Produced by Yehuda Shiran and Tomer Shiran
Created: January 18, 2000
Revised: January 18, 2000
URL: http://www.webreference.com/js/column56/template.html