使用 C# 在 Windows Phone 7 中开发电子邮件客户端应用程序

发布于 2024-12-17 00:57:39 字数 805 浏览 0 评论 0原文

我正在开始 Windows Phone 7 编程。对于我的一个程序,我需要发送电子邮件。例如我想使用谷歌发送电子邮件。对于桌面应用程序来说是可以做到的。对于 Windows Phone 7,我找到了与此相关的 EmailComposeTask 术语。但我不知道如何使用它登录或发送电子邮件。我在网上找到了一些代码,但这些代码也不起作用。这是代码:

EmailComposeTask emailcomposer = new EmailComposeTask();
emailcomposer.To"<a href="mailto:[email protected]">[email protected]</a>";
emailcomposer.Subject = "subject from test app";
emailcomposer.Body = "This is a test mail from Email Composer";
emailcomposer.Show();

但是这里的邮件是从哪个电子邮件客户端发送的? 解决方案是什么?

I am starting windows phone 7 programming. For one of my program I need to send email. For example I want to send email using google. For desktop application is can do it. For Windows Phone 7 I found EmailComposeTask term for related on this. But I don't know how to login or sending email using this. I find some code in net but those are not working also. Here is the code:

EmailComposeTask emailcomposer = new EmailComposeTask();
emailcomposer.To"<a href="mailto:[email protected]">[email protected]</a>";
emailcomposer.Subject = "subject from test app";
emailcomposer.Body = "This is a test mail from Email Composer";
emailcomposer.Show();

But here from which email client the mail is send?
What will be the solution?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

缱倦旧时光 2024-12-24 00:57:39

我在网上找到了一些代码,但这些代码也不起作用。这是
代码......但是这里的邮件是从哪个电子邮件客户端发送的?

手机将启动已安装的电子邮件客户端。我假设 Windows Phone 是否与 Android 类似,这将取决于用户选择哪个应用程序作为默认应用程序。

您是否实际运行过这段代码来看看它做了什么?您想要做的事情并不是 100% 清楚。您现在所拥有的只是简单地向用户提供可能使用其系统电子邮件帐户发送电子邮件的功能,当然不会使用您的谷歌邮件帐户,甚至保证使用谷歌帐户。

i find some code in net but those are not working also.here is the
code.........but here from which email client the mail is send?

The phone would launch the installed email client. I would assume if Windows Phone is anything like Android this would depend on which application the user selected as the default.

Have you actually ran this code to see what it does. What you are trying to do is not 100% clear. What you have right now would simply offer the user to send an email likely using THEIR system email account, certainly would not use your google mail account, or even be guaranteed to use a google account.

回首观望 2024-12-24 00:57:39

您实际上遇到了问题,因为模拟器的功能已锁定。此问题重复:如何设置电子邮件帐户在 Windows Phone 7 模拟器上?

You are actually facing problems because the emulator is feature locked. This question is a repeat of: How to setup email account on Windows Phone 7 emulator? .

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文