HTML toolbar commands versus templates

HTML toolbar commands versus templates

3
NewbieNewbie
3

    Oct 18, 2008#1

    Hello,
    I'm trying out the latest version of UltraEdit. So far, I like it. I have a question about the HTML toolbar features, particularly the HTML User Commands. Here's what I'd like to do:
    By clicking the corresponding button, I want to insert a chunk of code. I'm an ASP programmer so it might look like this:

    Code: Select all

    with response
         .write "|"
    end with
    Easy, and I've made this work no problem. My question is: Can I also assign hotkeys to this button so I don't have to click, I just press the corresponding keys, say ctrl-shift-r ?

    Maybe there is some other feature in UltraEdit that works similarly that I've overlooked???

    If I can get this to work, I'd gladly pay for this program. Your responses are much appreciated!

    6,603548
    Grand MasterGrand Master
    6,603548

      Oct 19, 2008#2

      It is not possible to assign a hotkey or a chord (fast typed sequence of keys) to a HTML toolbar user command, only to the standard HTML toolbar commands. But you can use templates. Templates are very similar to the HTML toolbar commands.

      The differences are:
      1. Templates are stored in a binary file instead of uedit32.ini (or registry). But all templates in the template file are automatically loaded when starting of UltraEdit like the HTML toolbar commands. Changing the directory for the template file gives the possibility to quickly selected a different list of templates for example for a completely other project.
      2. The character used for marking the cursor position is different. In templates the character ^ must be used while in HTML toolbar commands the character | must be used to mark the cursor position or the position where the selected text should appear after inserting the template or HTML toolbar command.
      3. For all of the up to 50 templates (0-49) a hotkey or chord can be configured at Advanced - Configuration Key Mapping. The commands are InsertTemplatex with x = 0...49. But a hotkey or a chord can be assigned only for the standard HTML toolbar commands, not for the HTML toolbar user commands.
      4. Templates can be inserted also during a macro or script execution, but not the HTML toolbar commands.
      5. For HTML toolbar commands an icon or bitmap can be specified, but not for templates (not directly). Also the HTML toolbar commands support a customized tooltip, but not templates. So the usage of HTML toolbar commands is often the better choice for the usage in a toolbar.
      6. Some standard HTML toolbar commands which can be nevertheless customized are supported with special built-in code like the bulleted or order list. On the other hand for templates some special template strings are available to customize date/time strings or file names.
      The first 10 templates can be also inserted directly from the menu Insert, the others via Insert Template. The first 10 templates can be also added to a customized toolbar. All 50 templates can be inserted with a double click on the template name in the template list view opend with a click on View - Views/Lists - Template List. With a right click on the template list view a context menu opens which shows you 2 items for modifying or inserting a template.

      See the IDM power tip Custom user-defined templates how to define templates. But before you first time open this dialog to define your first template, open Advanced - Configuration - Directories and specify the directory where the template file should be stored. A good place would be the directory of uedit32.ini. You can see the path of uedit32.ini at Advanced - Configuration - Application Layout - Advanced. It is for UE v14.20 by default something like:

      C:\Documents and Settings\username\Application Data\UltraEdit\
      Best regards from an UC/UE/UES for Windows user from Austria

      3
      NewbieNewbie
      3

        Oct 19, 2008#3

        Thank you, Mofi. It looks like templates are the way to go for my needs, especially that I only need eight or so templates and I can assign the first 10 templates to a key chord.