• 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: Can´t move mail message
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Can´t move mail message


  • Subject: Re: Can´t move mail message
  • From: Juan Pablo Garcia <email@hidden>
  • Date: Mon, 24 Jan 2005 07:07:59 +0100

Thanks for your answers, but it doesn´t work either.

Michelle: I get the s from a popupmenu selection from RealBasic, where it is treated as string.

Andrew: It continues without working even if I remove the braces or parentheses. Whenever I treat is as a variable it doesn´t work, but if I hard code the name of any of my mailboxes it works like a charm.

The other suspicious thing is that it doesn´t trigger any errors, it just doesn´t move the message. I supposed it was because of using "selection", but it does work telling it to go to a name of mailbox as string.

Any ideas?

regards,

JP

El Jan 24, 2005, a las 3:09 AM, Andrew Oliver escribió:

On 1/23/05 5:42 PM, "Juan Pablo Garcia" <email@hidden>
wrote:


Hi:

if I replace the s variable in the code down here with a mailbox name
it works, but getting the mailbox as a parameter doesn´t.

to check things, I invoke a display dialog with the s variable and it
works. I don ´t understand why the string is there for the display
dialog, but it gets "lost" somewhere for the move command.

I´m invoking this applescript code from a RealBasic Application.-



on run {s}
tell application "Mail"
move selection to mailbox {s}
end tell
end run

thanks a lot,

By enslosing 's' in curly braces you're coercing it to a list. Mail.app
interprets this as trying to move a message to a list of mailboxes, which it
can't do, hence the error.


The display dialog works because display dialog will silently coerce lists
to strings in order to display them.


Try removing the curly braces:

...
   move selection to mailbox s
...

Andrew
:)


_______________________________________________ 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
  • Follow-Ups:
    • Re: Can´t move mail message
      • From: Michelle Steiner <email@hidden>
References: 
 >Re: Can ´ t move mail message (From: Andrew Oliver <email@hidden>)

  • Prev by Date: Open Filemaker Remote with Password
  • Next by Date: Re: Can´t move mail message
  • Previous by thread: Re: Can ´ t move mail message
  • Next by thread: Re: Can´t move mail message
  • Index(es):
    • Date
    • Thread