• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Scripting Terminal
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Scripting Terminal


  • Subject: Re: Scripting Terminal
  • From: Paul Scott <email@hidden>
  • Date: Thu, 24 Jun 2010 18:26:06 -0700

That does, indeed. Thank you.

But, I don't understand why "set s to contents of t" doesn't work. The value of s should be of type text. But it isn't. Looks like a bug to me, but is it? Or, is my understanding lacking?

Paul

On Jun 24, 2010, at 6:12 PM, email@hidden wrote:

> This works:
> tell application "Terminal"
> 	tell front window
> 		set t to selected tab
> 		do script "1G" in t
> 		set s to properties of t
> 		display dialog contents of s
> 	end tell
> end tell
>
> hth,
>
> ed
> On Jun 24, 2010, at 5:11pm, Paul Scott wrote:
>
>> Why doesn't this work?
>>
>> tell application "Terminal"
>>   tell front window
>>       set t to selected tab
>>       do script "1G" in t
>>       set s to contents of t
>>       display dialog s
>>   end tell
>> end tell
>>
>> But this does:
>>
>> tell application "Terminal"
>>   tell front window
>>       do script "1G" in selected tab
>>       set s to contents of selected tab
>>       display dialog s
>>   end tell
>> end tell
>>
>> ???
>>
>> Paul

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

References: 
 >Scripting Terminal (From: Paul Scott <email@hidden>)
 >Re: Scripting Terminal (From: "email@hidden" <email@hidden>)

  • Prev by Date: Re: Scripting Terminal
  • Next by Date: Re: more tell/scoping problems
  • Previous by thread: Re: Scripting Terminal
  • Next by thread: Re: Scripting Terminal
  • Index(es):
    • Date
    • Thread