Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: using an external editor on Mac OS X


From   Benjamin Hulley <[email protected]>
To   [email protected]
Subject   st: using an external editor on Mac OS X
Date   Tue, 21 Oct 2003 14:45:55 -0700

Hi All

I'm trying to integrate TextWrangler (a smaller BBedit) more closely with Stata and have written a couple of applescripts to pass a file or a selection of commands to Stata. I invoke TextWrangler with the shell command and it works when creating a new file, but it does not work when invoking TextWrangler with out opening a new file. Specifically, when I type:
.shell edit -c myfile.do
TextWrangler opens up with the new file "myfile.do", and I can use my applescripts to send the file back to Stata. However, if I then type:
.shell edit -l
TextWrangler comes to the front and the Stata icon bounces in the dock (which it doesn't do if creating a new file). The problem is that if I try to send the file back to Stata, the TextWrangler menu becomes grayed out and the commands do not execute until I manually switch to Stata.

I believe the problem is independent of the applescripts because Stata's behavior changes for the two different ways of invoking TextWrangler.

I'm sorry if this explanation is a little confusing, but does anyone have an idea why one way works and the other doesn't and a way around this problem?

Thanks in advance

Ben

*
* For searches and help try:
* http://www.stata.com/support/faqs/res/findit.html
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/




© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index