At 10:29 AM -0700 7/11/03, Chris Nandor wrote:

and here's a Perl tutorial:
[snip way too many lines of tutorial, apparently intended to make perl look
a lot harder than it is]

Here is what, perhaps, you meant:

Open BBEdit
Type
   print "Hello, world."
Run the script


Yes, that's one way to run a Perl script, but Apple doesn't bundle BBEdit with OS X. I wasn't trying to make Perl look harder than it is. I was illustrating the baseline of knowledge you need to get started.



 Now that you've mastered Perl and Applescript, it should be trivial
 to use either language to create a script that extracts information
 from a FileMaker database and places it into a QuarkXPress template,
 then imports images into the document from a remote server, applies
 the appropriate style sheets to the text, prints the document on a
 color printer, exports the document as a PDF, saves the text as an
 HTML file, then opens the HTML file in BBEdit.

Yes, quite. A snippet:


   use Mac::Glue;
   my $fm = new Mac::Glue 'FileMaker Pro';

$fm->obj(file => $file)->open;

   # get fields
   my @fields = $fm->prop(name => fields => database => 1)->get;

   # get records where second cell isn't empty
   my @data = $fm->obj(records =>
      whose(NOT => [cell => 2, equals => '']),
      database => 1
   )->get;

etc.

Or did you intend to mean that manipulating data in AppleScript was hard?


If you find this difficult to accomplish in Perl

I don't. :-)

I think you might be a special case. Not everyone has written Mac::Glue or maintained MacPerl. If you are claiming that you can do everything with Perl and Mac::Glue that you can with Applescript, then I won't dispute you. But don't pretend it's just as easy for a novice.


My original point stands: getting rid of Applescript because Robin prefers Perl is a bad idea.

I wish I had cross-posted my original reply to MACSCPT so we could have a proper flamewar.

--
Chip Howland
The Sportsman's Guide

Reply via email to