• 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: Finding Items Within A Folder (Filemaker) AS
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Finding Items Within A Folder (Filemaker) AS


  • Subject: Re: Finding Items Within A Folder (Filemaker) AS
  • From: Bryan <email@hidden>
  • Date: Thu, 04 Oct 2001 02:07:00 -0400
  • Organization: Apex Radiology

tell application "FileMaker Pro"
activate
tell database "My Photo Database"
tell layout 1
set myimagename to cell "IMAGE NAME" of current record
end tell
end tell
end tell

tell application "Finder"
activate
if file myimagename of folder "IMAGES" exists then
set mytext to "1"
else
set mytext to "0"
end if
end tell

tell application "FileMaker Pro"
activate
tell database "My Photo Database"
tell layout 1
copy mytext to cell "IMAGE EXIST" of current record
end tell
end tell
end tell


Bryan Kaufman


John Haley wrote:

> In your second tell to FileMaker shouldn't you tell FileMaker to go to the
> next record?
>
> Also, I think you usually want to tell FileMaker which database to talk to
> as a rule, therefore you should have a second tell statement...
> tell application "FileMaker"
> tell document "My Photo Database"
> --do stuff
> go to record after current record
> end tell
> end tell
>
> From: Kevin Morrison <email@hidden>
> Date: Wed, 03 Oct 2001 11:25:53 -0700
> To: <email@hidden>
> Subject: Finding Items Within A Folder (Filemaker) AS
>
> Applescript Wizards,
>
> I'm battling this little script. Pretty pitiful, but long days and late
> hours have turned my mind into a jello like mush which can't seem to find
> the problem. Insights appreciated!
>
> I have a Filemaker database that has a list of image names (field: IMAGE
> NAME) as well as blank text field- (IMAGE EXIST).
>
> What I want is for AS too look at the IMAGE NAME in the FM database, and if
> it finds a picture with that name in the IMAGES folder, then put a "1" in
> the IMAGE EXIST field, if no image is found a "0" in the field.
>
> Seems simple enough, but it only wants to work for the first record. I have
> it loop from within FM, but it won't set mytext beyond the first record
> (though it does loop through all the records).
>
> tell application "FileMaker Pro"
> activate
> set myimagename to cell "IMAGE NAME" of current record
> end tell
>
> tell application "Finder"
> activate
> if file myimagename of folder "IMAGES" exists then
> set mytext to "1"
> else
> set mytext to "0"
> end if
> end tell
>
> tell application "FileMaker Pro"
> activate
> set cell "IMAGE EXIST" to mytext
> end tell
>
> Thanks in advance to any direction available.
>
> Kevin
>
> Kevin Morrison
> Dorian Studio Inc
> _______________________________________________
> applescript-users mailing list
> email@hidden
> http://www.lists.apple.com/mailman/listinfo/applescript-users
> _______________________________________________
> applescript-users mailing list
> email@hidden
> http://www.lists.apple.com/mailman/listinfo/applescript-users

[demime 0.98b removed an attachment of type text/x-vcard which had a name of bryan.vcf]


References: 
 >Re: Finding Items Within A Folder (Filemaker) AS (From: John Haley <email@hidden>)

  • Prev by Date: Re: Applets dieing under 10.1
  • Next by Date: Re: What about facespan
  • Previous by thread: Re: Finding Items Within A Folder (Filemaker) AS
  • Next by thread: Re: Finding Items Within A Folder (Filemaker) AS
  • Index(es):
    • Date
    • Thread