• 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: new to ascript & filemaker
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: new to ascript & filemaker


  • Subject: Re: new to ascript & filemaker
  • From: Gary Lists <email@hidden>
  • Date: Mon, 01 Dec 2003 20:43:43 -0500
  • Http: //bau2.uibk.ac.at/sg/python/Sounds/HolyGrail.wav/taunt.wav

On or about 12-01-03 6:50 PM, Malcolm Fitzgerald wrote:

> Shane may know how to get Photoshop file properties from an image.
> You can get the finder to reveal some aspects of the file with "info
> for". Get the file properties and dump them into fmp. Simon's
> suggestion is good - use file references rather than copying the
> whole image into the database.
>
> You can set up a layout that contains only the fields you want to
> fill then say something like

Good beginning, Malcolm. There are a couple of errors generated (OMM, OS9),
but this very slight revision will do the trick:

-- // begin
set filePath to (choose file of type {"JPEG", "GIFf"})
tell application "Finder" to set fileRecord to (get info for filePath)
set pathString to filePath as string -- for later

-- build a long record of all data we are passing to FM
tell fileRecord to set propertyList to {it's name, it's modification date as
string, it's file type, it's file creator} -- NO BREAK, NO WRAP, ONE LINE
set end of propertyList to pathString -- for text field with path
set end of propertyList to (pathString as file) -- image file ref

-- make a new record in frontmost DB at current layout...I'm lazy
go to record ID (ID of (create new record with data propertyList))
-- // end


Here is a sample FM6 file and AppleScript called "Image Testing". It shows
the auto-insertion of a reference, as well as the launching of the file in
the Finder. (You might also be interested in FM Field Reporter, which is
useful to show how to determine, by AS, whether a container object is
embedded or referenced.)

"Image Testing.sit.hqx" ...
<http://NicheCrafters.com/cgi-bin/getfile.pl?browse&filemaker>

--
Gary
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: new to ascript & filemaker (From: Malcolm Fitzgerald <email@hidden>)

  • Prev by Date: Re: Mounting remote folder question
  • Next by Date: Re: Mounting remote folder question
  • Previous by thread: Re: new to ascript & filemaker
  • Next by thread: RE: new to ascript & filemaker
  • Index(es):
    • Date
    • Thread