Announcement

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

  • Execute single commands of a Do-File on Mac

    Hello everyone,

    my question is: How do I execute single commands of a Do-File on a Mac? In Windows I select the command that I would like to execute and then press Ctrl+D. Is there a similar option on the Mac? On some sources on the Internet I found the combination command+shift+D, but that unfortunately doesn't work.

    Thanks in advance for your help.

  • #2
    Jan, the command+shift+D is the correct way to execute a selected (highlighted) line. If the line is not highlighted, command+shift+D will execute from the beginning of the do-file editor. Can you describe how it doesn't work for you?

    Comment


    • #3
      Adding to Daniel's answer, the "Do" button at the top the Do-file Editor window will also execute one or more selected (highlighted) lines, as will one of the items on the View > Do-file Editor sub-menu.

      Comment


      • #4
        I don't have a Mac on my own, but I am currently teaching a Stata course at university and one of the students described me the problem, that with command+shift+D it didn't work. I'm not sure yet if the approach using the Do-button worked for her. Thank you very much for your replies, even though it's a question about the basics of Stata, I appreciate it. I'll try to figure out, if the problem maybe lies somewhere else then.

        Comment


        • #5
          Let me then mention one other thing. In the screenshot of the Do-file Editor below, line 5 was selected and highlighted by clicking to the left of the line number. The blue box on line 4 is neither selection nor highlight (6 years and I have no idea what it is, to be honest) and was created by clicking to the right of the line number. Perhaps your student has inadvertently gotten the blue box rather than the line selection.

          Click image for larger version

Name:	selection.png
Views:	1
Size:	110.6 KB
ID:	1550737

          Comment

          Working...
          X