简体   繁体   English

使用Delphi xe4,邮件客户端将无法打开

[英]Using Delphi xe4, mail client will not open

Referring to a different article/question: Delphi XE4 iOS open email program not working 引用其他文章/问题: Delphi XE4 iOS开放电子邮件程序不起作用

Same symptoms apply to my situation. 同样的症状适用于我的情况。 When debugging in the iPhone simulator, I can paste into the Safari Web Browser, 'mailto:info@example.com?Subject=test' (or whatever I desire, really) and the simulator then proceeds to open the Apple Mail Client with the specified parameters. 在iPhone模拟器中进行调试时,我可以将粘贴到Safari Web浏览器中,“ mailto:info@example.com?Subject = test”(或我真正想要的任何东西),然后模拟器将继续使用以下步骤打开Apple Mail Client:指定的参数。

BUT, in my app when using the line: 但是,在我的应用程序中,使用以下行时:

    OpenURL('mailto:info@example.com?Subject=test');

Well, nothing happens. 好吧,什么都没有发生。 I can replace the MailTo text with a web address such as, StackOverflow.com, and it works perfectly fine, but just doesn't when attempting to open the mail client. 我可以使用诸如StackOverflow.com之类的网址替换MailTo文本,它的工作原理非常好,但是在尝试打开邮件客户端时却不能。

Using Delphi Xe4, developing an app for iOS. 使用Delphi Xe4开发适用于iOS的应用程序。 Using the Apple.Utils framework provided with the Delphi Samples. 使用Delphi示例提供的Apple.Utils框架。

Am I missing anything? 我有什么想念的吗? Or is there an easier way to open the mail client? 还是有一种更简单的方法来打开邮件客户端?

No one responded. 没有人回应。 There was an easier way - using an action sheet to perform the same sharing functionality that we see in just about all Apple software products. 有一种更简单的方法-使用操作表执行与我们在几乎所有Apple软件产品中看到的相同的共享功能。 It is located in an example in the Delphi Samples. 它位于Delphi示例中的一个示例中。 You can send text, email, etc. etc. Also can attach pictures. 您可以发送文本,电子邮件等,也可以附加图片。

Hint: The share feature functionality does not work in the simulator but does actually work on devices. 提示:共享功能在模拟器中不起作用,但实际上在设备上起作用。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM