• 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: Create record in FileMaker
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Create record in FileMaker


  • Subject: RE: Create record in FileMaker
  • From: "Steve Suranie" <email@hidden>
  • Date: Wed, 29 Sep 2004 09:01:15 -0400
  • Thread-topic: Create record in FileMaker

This might help

set thePath to path to desktop as alias
set dbPath to (thePath as string) & "FaxRecordResponse.fp7" as alias

tell application "Filemaker Developer"
try

openDB(dbPath)

tell front document
set thisRecord to create new record
set cell "FIELD NAME GOES HERE" of thisRecord to "Texas"
set cell "FIELD NAME GOES HERE" of thisRecord to "12548"
set cell "FIELD NAME GOES HERE" of thisRecord to "abc"
end tell

on error errMsg
display dialog "There was an error in Filemaker Developer" & return & return & errMsg
end try
end tell

on openDB(dbPath)
	set dbName to last text item of (dbPath as string)
	set dbPath to dbPath as alias
	tell application "FileMaker Pro"
		set dbCount to count of every document
		if dbCount > 0 then
			repeat while name of front document ? dbName
				close front document
			end repeat
		else
			open dbPath
		end if
	end tell
end openDB


> ----------
> From: 	applescript-users-bounces+ssuranie=email@hidden on behalf of Lawrence B. Camp
> Sent: 	Tuesday, September 28, 2004 11:10 PM
> To: 	email@hidden
> Subject: 	Create record in FileMaker
>
> <<File: ATT586494.txt>>
> I would appreciate some basic help with an AppleScript to create a record in a FileMaker database.  The FM database will be running when the AppleScript runs.  The FM file is: FaxRecordResponse.fp7.
>
> Here what I have now:
>
> tell application "FileMaker Developer"
>     open file "FaxRecordResponse.fp7"
>     create record with data {"Texas", "12548", "abc"}
> end tell
>
> FileMaker returns the error that > "> FaxRecordResponse.fp7> ">  could not be opened (not found).
>
> How do I tell FileMaker where to find the file?  Currently it> '> s on the desktop.  I> '> ve tried the script with the file open and the error is the same.
>
> Thanks for your help,
>
> --
> Lawrence B. Camp
> 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:

This email sent to email@hidden

  • Prev by Date: Re: Create record in FileMaker
  • Next by Date: RE: Create record in FileMaker
  • Previous by thread: Re: Create record in FileMaker
  • Next by thread: RE: Create record in FileMaker
  • Index(es):
    • Date
    • Thread