• 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: TextEdit oddity
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: TextEdit oddity


  • Subject: Re: TextEdit oddity
  • From: Shane Stanley <email@hidden>
  • Date: Wed, 21 May 2014 14:25:37 +1000

On 21 May 2014, at 11:02 am, Ron Hunsinger <email@hidden> wrote:

AHA!!!

You've bumped up against the maximum size of an AppleEvent record.

That's an interesting theory, but it doesn't bear a lot of scrutiny. For starters, the error suggests something happening well beyond AppleScript. But perhaps more importantly, this simple example suggests you can pass a much bigger string than your theory would suggest:

set x to "blah blah blah blah " & return
repeat 17 times
set x to x & x
end repeat
set y to length of x
tell application "BBEdit"
make new document
set contents of window 1 to x
set z to length of contents of window 1
end tell
return {y, z, 2 ^ 17 as miles as integer, z > 2 ^ 17}
--> {2752512, 2752512, 131072, true}

As you can see, your 2^17-character limit is being exceeded by a factor of roughly 20 without problems. 


-- 
Shane Stanley <email@hidden>
<www.macosxautomation.com/applescript/apps/>

 _______________________________________________
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: 
 >TextEdit oddity (From: "koenig.yvan" <email@hidden>)
 >Re: TextEdit oddity (From: Shane Stanley <email@hidden>)
 >Re: TextEdit oddity (From: "koenig.yvan" <email@hidden>)
 >Re: TextEdit oddity (From: Deivy Petrescu <email@hidden>)
 >Re: TextEdit oddity (From: "koenig.yvan" <email@hidden>)
 >Re: TextEdit oddity (From: Ron Hunsinger <email@hidden>)

  • Prev by Date: Re: TextEdit oddity
  • Next by Date: Re: TextEdit oddity
  • Previous by thread: Re: TextEdit oddity
  • Next by thread: Re: TextEdit oddity
  • Index(es):
    • Date
    • Thread