• 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: Gui script for Preview
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Gui script for Preview


  • Subject: Re: Gui script for Preview
  • From: KOENIG Yvan <email@hidden>
  • Date: Sat, 05 May 2012 15:11:35 +0200

Le 5 mai 2012 à 14:48, Robert Poland <email@hidden> a écrit :

> Has anyone gotten this to work? I get the error "Can't make some data into the expected type".
>
> set factor to 0.5
> set f to "Desktop:chart1.gif"
> set newf to "Desktop:Scans ƒ"
> set {x, y} to (image info for f)'s {pixel width, pixel height}
> set w to make new graphic window with properties {pagewidth:x * factor, pageheight:y * factor}
> BeginFigure(w)
> DrawImage(f, {0, 0, x * factor, y * factor}, "")
> EndFigure()
> save w in newt
>

(1)  I'm not sure that
>  "Desktop:chart1.gif"

is a valid reference to the file.

An HFS path starts from the volume name so the path would be :

<startupVolume>:Users:<userAccount>: Desktop:chart1.gif

(2) I'm not sure that image for info accepts a string as a valid reference. I guess that a file or an alias would be better.

Yvan KOENIG (VALLAURIS, France) samedi 5 mai 2012 15:11:30



 _______________________________________________
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


  • Follow-Ups:
    • Re: Gui script for Preview
      • From: Robert Poland <email@hidden>
References: 
 >Gui script for Preview (From: Alex Zavatone <email@hidden>)
 >Re: Gui script for Preview (From: Emmanuel LEVY <email@hidden>)
 >Re: Gui script for Preview (From: Christopher Stone <email@hidden>)
 >Re: Gui script for Preview (From: Emmanuel LEVY <email@hidden>)
 >Re: Gui script for Preview (From: Robert Poland <email@hidden>)

  • Prev by Date: Re: Gui script for Preview
  • Next by Date: Re: Cannot open "On My Mac" mailboxes
  • Previous by thread: Re: Gui script for Preview
  • Next by thread: Re: Gui script for Preview
  • Index(es):
    • Date
    • Thread