gpt4 book ai didi

android - 从 Android 应用程序访问收件箱消息

转载 作者:行者123 更新时间:2023-11-29 02:06:52 27 4
gpt4 key购买 nike

我需要有关 Android 短信应用程序的帮助。我正在从我的 android 应用程序向手机号码发送一条消息。我需要检查消息是否已从我的应用程序发送到该手机号码的收件箱中。我需要检查发送到手机号码的消息是否已送达。 IE。目的地匹配。如何从 Android 应用程序访问 INBOX 消息。请指导我解决这个问题。如果有人帮助我提供示例工作示例,那将会很有帮助。

提前致谢。

最佳答案

如何从 android 应用程序访问 INBOX messagr,答案如下,

Uri uri = Uri.parse("content://sms/inbox");
Cursor cursor = context.getContentResolver().query(uri, null, null, null, null);
while (cursor.moveToNext())
{
// Retrieve sms
// see column "address" for comparing

// Then update the sms and set the column "read" to 1
}

关于android - 从 Android 应用程序访问收件箱消息,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9543411/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com