PDA

View Full Version : Can we embed Apple script inside iphone appplication?




shweta13
Aug 11, 2008, 09:31 AM
Hi all,

Can we embed Apple script inside iphone appplication? If so how do we do it?



Cromulent
Aug 11, 2008, 09:47 AM
Hi all,

Can we embed Apple script inside iphone appplication? If so how do we do it?

No. Applescript is not supported on the iPhone.

firewood
Aug 11, 2008, 12:13 PM
Not Applescript, but you can embed Javascript inside an app which can be run inside a UIWebView.

shweta13
Aug 12, 2008, 02:07 AM
Not Applescript, but you can embed Javascript inside an app which can be run inside a UIWebView.

Hi,

So we can send mails using javascript inside UIWebView?

kainjow
Aug 12, 2008, 02:59 AM
Use the mailto: URL

shweta13
Aug 12, 2008, 03:25 AM
Use the mailto: URL

Hi,

Sorry i dont kno javascript...can you please tell me how to use mailto: URL in javascript...i want to directly invoke "mailto" without the help of controls such as buttons etc...

kainjow
Aug 12, 2008, 03:29 AM
Last time I did JavaScript, it was location.href = "mailto:user@aol.com?subject=test&message=test";

The mailto: URL on the iPhone opens the a new message form, it doesn't send an email. If you need to send an email without user interaction, you'll have to use a server somewhere to do that.

Sbrocket
Aug 12, 2008, 04:26 AM
Rather than use JavaScript, you can use -[UIApplication openURL:] to open a new mail in MobileMail.app. Keep in mind that is will terminate your own application.


[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@""mailto:user@aol.com?subject=test&message=test"]];