Re: applescript
- To: mathgroup at smc.vnet.net
- Subject: [mg108529] Re: applescript
- From: "alexxx.magni at gmail.com" <alexxx.magni at gmail.com>
- Date: Mon, 22 Mar 2010 02:38:52 -0500 (EST)
- References: <hnicpk$st7$1@smc.vnet.net> <hnss2a$5qh$1@smc.vnet.net>
On 20 Mar, 08:46, Armand Tamzarian <mike.honeychu... at gmail.com> wrote: > On Mar 18, 4:34 am, "alexxx.ma... at gmail.com" <alexxx.ma... at gmail.com> > wrote: > > > > > it's a pity that nobody seemed interested, but for the sake of future > > users googling about this problem, here's what I found: > > > 1) by using this simple script (thanks to Achilleas Lazarides) > > > tell application "Mathematrica" > > question="FactorInteger[987654321]" > > set x to do script question > > display dialog x > > end tell > > > I get the answer {{3,2},{17,2},{379721,1}} > > > 2) by this instead: > > > tell application "Mathematica" > > set s to "Graphics3D[Table[{RGBColor[RandomReal[1, 3]], > > Sphere[RandomReal[3, 3], RandomReal[{0.2, 0.4}]]}, {i, 5}], Boxed -> > > False]" > > set es to "Export[\"a.pdf\"," & s & "]" > > do script es > > end tell > > > I get a perfect pdf file with the output of any graphic command > > > alessandro > > > On 14 Mar, 11:12, "alexxx.ma... at gmail.com" <alexxx.ma... at gmail.com> > > wrote: > > > > hi everybody, > > > after using Linux machines since forever, I am now using a macbook, > > > and I just discovered what is IMHO the one and only feature where OSX > > > leaves Linux (and Win of course ;-) behind: the universal ability to > > > make apps communicate one with the other via Applescript. > > > (dont flame me: I know I can link Mathematica with C apps and so on..=