Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #8988
    derekcohen
    Participant

    I tried recording a macro to sort a selection by doing
    Narrowing on
    Sort a-z
    Narrowing off

    but it merely recorded mouse positions.

    What’s the API calls for this?

    thanks

    Derek

    #8993
    Yutaka Emura
    Keymaster

    Hello Derek,

    Not all operations are recorded automatically. Please see Help for macro methods. Here is an example:

    Narrowing on:
    editor.ExecuteCommandByID(4457);
    http://www.emeditor.com/help/cmd/edit/narrowing_on.htm

    Narrowing off:
    editor.ExecuteCommandByID(4458);
    http://www.emeditor.com/help/cmd/edit/narrowing_off.htm

    Sort A to Z:
    editor.ExecuteCommandByID(4477);
    http://www.emeditor.com/help/cmd/edit/sort_text_a.htm

    #9014
    derekcohen
    Participant

    That’s great.

    I have created a macro

    //narrowing on
    editor.ExecuteCommandByID(4457);
    //sort A-Z
    editor.ExecuteCommandByID(4477);
    //narrowing off
    editor.ExecuteCommandByID(4458);

    and added it to one of the menus but it displays the name of the macro file – is there a way for it to display “Sort selection” rather than “sortselection.jsee”

    thanks

    Derek

    #9019
    Yutaka Emura
    Keymaster

    Hello Derek,

    When you add a macro to a menu, there is a text box called “Name” on the Menu Properties. You can enter whatever name you want to be appeared in the menu.

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.