General XMetaL Discussion

XMetaL Community Forum General XMetaL Discussion Is it possible to do a keyboard shortcut for a button?

  • luskds

    Is it possible to do a keyboard shortcut for a button?

    Participants 1
    Replies 2
    Last Activity 6 years, 3 months ago

    Specifically, I am trying to do a keyboard shortcut to toggle the change tracking button.  Recording a macro just tells me it has no actions to record.  I didn't see it in the keyboard shortcut list or when I did a post search.
    I am using XMetal Author Enterprise 10 on Windows 7 (some of our users are on Windows 10 and/or XMetal Author Essentials 10).

    Reply

    Derek Read

    Reply to: Is it possible to do a keyboard shortcut for a button?

    Macro recording is pretty much limited to things that directly affect a document using the keyboard pasting content, typing content, moving around in the document, etc.

    The immediate solution for you would be to use Alt+T followed by C.

    In XMetaL Author shortcuts are assigned to macros (a macro might have an associated button on a toolbar or menu but that is incidental). For built-in functions like the Change Tracking feature there is no macro so you cannot assign (or reassign) a shortcut key directly to a built-in function. You would need to write a macro that either duplicates the feature or otherwise runs the feature and assign a keystroke to the macro. There are APIs that let you turn Change Tracking on and off so the following would do it in this case:

    [code=Toggle Change Tracking, JScript example]if (ActiveDocument.TrackRevisions == false) {
    ActiveDocument.TrackRevisions = true;
    }
    else {
    ActiveDocument.TrackRevisions = false;
    }[/code]

    Reply

    luskds

    Reply to: Is it possible to do a keyboard shortcut for a button?

    Thanks Derek.  That looks like a simple enough macro to write.  I'll give it a shot.

    Reply

  • You must be logged in to reply to this topic.

Lost Your Password?

Products
Downloads
Support