In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] (John Delacour) 
wrote:

> I'm trying to work out how to make a new message using the Perl glue 
> I've created for Eudora.  It's going to take me a little while to 
> adapt to the Perl syntax, so I hope you don't mind my asking a few 
> dumb questions.
> 
> In AppleScript it would be
>       make message at end of mailbox ":Out"
> 
> and in the glue I made for Frontier the basic verb eudora.MS.new() is:
> 
> on new() {
>         M = core.create ('CSOm', 'euMS', 0, 0, insertionloc ('end ', 
> ['euMB'][":Out"]))}
> 
> What would the syntax be in Perl?

Sorry John, haven't read the list in a week.

Here's an example:

   use Mac::Glue ':all';  # get location()

   my $eudora = new Mac::Glue 'Eudora';
   my $box = $eudora->obj(mailbox => 'Out');
   my $mail = $eudora->make(
      new => 'message',
      at => location(end => $box)
   );

You can probably see how this compares:

   ['euMB'][":Out"] is like $eudora->obj(mailbox => 'Out')
   insertionloc('end ', ['euMB'][":Out"]) is like location(end => $box)
   core.create('CSOm', 'euMS', ...) is like $eudora->make(new => 'message')

etc.

The full example of creating, composing, and sending mail is in the 
distribution, in ex/eudora_send_mail, along with a bunch of other examples.

Feel free to ask any such questions, though you might want to Cc: me when 
you mail the list, since I only glance at the list about once a week or so.

-- 
Chris Nandor                      [EMAIL PROTECTED]    http://pudge.net/
Open Source Technology Group       [EMAIL PROTECTED]     http://ostg.com/

Reply via email to