how do I script 'right screen margin' in 7.0.5?

chris denesha cmd-list at 99main.com
Tue Sep 19 17:03:59 CDT 2006


At 03:55 PM 9/19/2006 -0500, you wrote:

>I think the problem is that when you copy prefs from one machine to  
>another, you're also copying the bounds of all the palettes. When  
>Creator is launched and the palettes are being created, the bounds is  
>loaded then constrained to the current screen resolution. So you need  
>to force the palettes to know that they need to be arranged according  
>to the current screen margins and the current screen resolution. Use  
>the Arrange Palettes menu item:
>
>tell application "MultiAd Creator Pro"
>         activate
>         set cmd to get command code of menu item "Arrange Palettes" of menu  
>"View"
>         do command cmd
>end tell

Oh, this is going to work!!!  I hadn't come across the Arrange Palettes command yet, very cool!!!  I actually got a hack to work before I came back to the list, but it involved changing the screen res away and back using the Jon's Commands osaxen - very messy!!!!!!

Unfortunately the AppleScript immediately errored out with 'MultiAd Creator Pro got an error: An object referenced in the AppleEvent doesn't exist' and highlighted the two words 'command code' in the set line.  Then I noticed I mis-spelled 'Palette' (not reading mail on the same MAC I'm coding on).

For completeness sake, I'll mention that you have to have an open document to use the View menu, so I create one and then close it after since my code is starting C7.

I must say again how wonderful it is to have a developer who actively reads the list and helps the community like this.  It really sets Multi-Ad apart from the rest, so hopefully you are compensated accordingly Steve!!


>Also, I hope your script that copies the prefs from one machine to  
>another isn't being run from within Creator or while Creator is running.

Nope!  it warns the user and asks for confirmation, then quits the process using the Akua Sweets osaxen.

chris

p.s. Creator rocks!



More information about the Creator mailing list