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

Re: Appearance OSAX


  • Subject: Re: Appearance OSAX
  • From: Håvard Graudo <email@hidden>
  • Date: Thu, 31 May 2007 20:44:49 +0200

I have been using that approach for some time and it works very well.

I found that they changed wording extensively from version 3.0 to 3.1 so scripts created this way will only work with a spesific version of the OSAX.
The item count limit seems to depend on current screen resolution, so you may find that scripts working on your large monitor fails on a MacBook. (It would be great to be able to ask for a smaller typeface)


Appearance OSAX is well worth the money. They also have great support. (I have no releations, just happy)

Håvard


Den 31. mai. 2007 kl. 18.00 skrev Simon Topliss:

For any Appearance OSAX users...

Today I needed a way to dynamically display a "better dialog" with an unknown number of check boxes. This example shows how this can be achieved. It can be easily be adapted for other field types. I'm not too sure what the limits are for each field type.

-- BEGIN SCRIPT EXAMPLE
set colourList to {"Cyan", "Magenta", "Yellow", "Black", "Gold", "Red"}
set dialogScriptString to "set dRes to display better dialog \"Select colours:\" fields {"
repeat with i from 1 to colourList's length
set dialogScriptString to dialogScriptString & "{kind:check box, name:\"" & item i of colourList & "\"},"
end repeat
set dialogScriptString to (text 1 thru -2 of dialogScriptString) & "} buttons {\"OK\", \"Cancel\"}"
set dRes to run script dialogScriptString
set coloursChosen to choices returned of dRes -- result is a list of all checked checkboxes
-- END SCRIPT EXAMPLE


It builds a string from the list and uses "run script" to compile and run it. Run script also returns the correct chosen "choices".

I don't think I've seen this offered as a solution before (no doubt I'm not the first to think of it!), so I thought I'd submit it for those who may need this functionality at some time.

Simon

ps. Appearance OSAX is a scripting addition available from http:// www.24usoftware.com/AppearanceOSAX. It's a great tool for anything other than standard "display dialog" can offer without resorting to Xcode.


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


This email sent to email@hidden

_______________________________________________ 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: 
 >Appearance OSAX (From: Simon Topliss <email@hidden>)

  • Prev by Date: Appearance OSAX
  • Next by Date: Script to select firefox menu item on startup
  • Previous by thread: Appearance OSAX
  • Next by thread: Script to select firefox menu item on startup
  • Index(es):
    • Date
    • Thread