Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Is it possible to add/edit shortcuts?

    I want to assign CTRL + ALT + B to the "run from the beginning" command in the do file. Is there a way to do it?

  • #2
    Not answer the question directly.

    On the do-file editor, if you don't highlight anything (cursor can be anywhere), using the usual "do" short-cut (Ctrl + D in Windows; Shift + Cmd + D in Mac) will already do what you're looking for.

    Comment


    • #3
      Ken Chui Not actually. The "run from the beginning command" runs the code from the start up to the point where your cursor is (you can see it in the Tools Window). Ctrl + D runs all the code.

      Comment


      • #4
        I have often wished for a "run from the beginning to the current cursor location" shortcut myself. There isn't any. But you can do it pretty quickly, at least in Windows, with Ctrl-Shift-Home (which selects from the beginning to the current cursor location) followed by Ctrl-D (which executes the highlighted code lines.)

        Comment


        • #5
          Quick and dirty but I often just type something like

          Code:
          STOP
          at the point i wish the do-file (editor contents) to stop. It's not a legal official command, so Stata indeed stops (for me).

          No objection to shortcuts, but one I don't use routinely is not one I will ever remember.

          Comment


          • #6
            Thank you Clyde Schechter and Nick Cox . Both worked. I am staying writing an ilegal "s" in the code.

            Comment

            Working...
            X