Does anyone know of a method (AppleScript, standalone app, or otherwise) for taking raw “forms” data which has been received via email (using OSX’s Mail.app) from a web site (e.g., name and address data), and converting it to tab-delimited text – so that it can be imported into a FileMaker database?
There are lots of threads about this topic (people, please use the search function for this BBS!); here’s one.
Jon
Why make more work for yourself than you need to?
It’s just as easy (if not easier) to have your script read the email and write the data directly into a new record in your Filemaker database. No intermediate files needed. Faster, too.
Hmm… Well, the reason I’m trolling in these waters for an answer is because some people browsing this forum may find that my problem is easy to solve (because they know scripting), or may consider the solution obvious (because they have solved it before). For me, however, not being a scripter, the problem is not easy, and the solution is not obvious.
Sure, launching a script and bringing the data straight into FileMaker is the right way to do the job… but who’s got the script?
This should get you started. I can’t provide an exact script since you didn’t provide an example of the mail message, but I’m assuming that the message contains a number of lines in the format:
variable: value
variable2: value 2
and that you have a Filemaker Pro database that has field names matching the variable labels (i.e. in this case you have a Filemaker Pro database with two fields called ‘variable’ and ‘variable2’
The premise of this script is that for each message passed in it extracts the message contents then performs some text parsing to work out the various fields. It then creates a new record in Filemaker Pro and populates the data with whatever records were passed in the email:
[This script was automatically tagged for color coded syntax by Convert Script to Markup Code]
It should be enough to get you started. You may need to make some changes, especially if the email doesn’t follow my assumptions or if the field names don’t match.
Well, I was afraid this would happen, but maybe hoping it would, too. It looks like I’m going to put in the time, and actually learn AppleScript.
Lazy me, I was hoping (still am) for someone to appear with a piece of shareware, with an intuitive interface, to move emailed forms data into FileMaker. But that particular solution has not appeared, and may not exist.
I’ve never thought of myself as having a brain (or the time) for programming, :rolleyes: but maybe I’m wrong. I can assemble furniture from Ikea.
I’m reading an AppleScript book (.pdf), so it may be a while before I can put your advice to good use. Thanks for taking the time to share some code.
</shameful admission>
Muchas gracias to the lovely Sascha, who spotted my post, and sent the following email:
i know one:
look at http://www.nullify.de/nullifySoftware/en/Software/nulliform.html
i guess that is what you need!!
sascha
Hi,
I downloaded MainEvents 1.3.1 and changed the sample script to script adobe acrobat.
It tells acrobat to show a dialogbox, this is a dialogbox of a plugin calls
“Enfocus Pitstop” wich we use to check PDF files. The script works till the dialogbox
show up, is it possible to script things in this dilaogbox with MainEvents??
tell application "Finder"
if exists items in folder "Dolf HD:Desktop Folder:PDFF:" then
set theFolderList to folder "Dolf HD:Desktop Folder:PDFF:"
set theNameList to ""
repeat with thisItem in theFolderList
set theNameList to (the name of thisItem)
tell application "Acrobat 5.0"
activate
open thisItem
end tell
exit repeat
end repeat
end if
end tell
tell application "Finder"
set targetApplication to application "Acrobat 5.0"
tell targetApplication
try
set menuListInfo to Query Menu List
end try
if (count of menuListInfo) is greater than 0 then
set menuListText to menu title of item 1 of menuListInfo
repeat with menuIndex from 2 to count of menuListInfo
set menuListText to menuListText & ", " & menu title of item menuIndex of menuListInfo
end repeat
end if
set menuInfo to Query Menu menu title "Certified PDF"
Select Menu Item menu title "Certified PDF" menu item text "Edit Properties..."
end tell
end tell