惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

The Cloudflare Blog
Microsoft Security Blog
Microsoft Security Blog
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
L
LangChain Blog
W
WeLiveSecurity
P
Proofpoint News Feed
月光博客
月光博客
NISL@THU
NISL@THU
L
LINUX DO - 最新话题
Webroot Blog
Webroot Blog
T
Threatpost
Y
Y Combinator Blog
www.infosecurity-magazine.com
www.infosecurity-magazine.com
T
Threat Research - Cisco Blogs
Vercel News
Vercel News
Jina AI
Jina AI
阮一峰的网络日志
阮一峰的网络日志
S
Schneier on Security
J
Java Code Geeks
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
小众软件
小众软件
MyScale Blog
MyScale Blog
N
News and Events Feed by Topic
Stack Overflow Blog
Stack Overflow Blog
有赞技术团队
有赞技术团队
The Hacker News
The Hacker News
Schneier on Security
Schneier on Security
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
Help Net Security
Help Net Security
Recent Announcements
Recent Announcements
S
Security @ Cisco Blogs
C
CXSECURITY Database RSS Feed - CXSecurity.com
S
Securelist
T
The Exploit Database - CXSecurity.com
云风的 BLOG
云风的 BLOG
C
Cisco Blogs
雷峰网
雷峰网
量子位
Google DeepMind News
Google DeepMind News
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
Spread Privacy
Spread Privacy
L
Lohrmann on Cybersecurity
I
Intezer
T
The Blog of Author Tim Ferriss
G
GRAHAM CLULEY
D
DataBreaches.Net
V
Vulnerabilities – Threatpost
P
Privacy & Cybersecurity Law Blog
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
罗磊的独立博客

博客园 - xin36933

浅析android OCR文字识别 Android中使用代码截图的各种方法总结 Android通过tcpdump抓包 Android 开机自动启动服务 SqlServer表死锁的解决方法 数据库 的事务日志已满。若要查明无法重用日志中的空间的原因,请参阅 sys.databases 中的 log_reuse_wait_desc 列。 修改Android工程版本 android利用剪切板来实现数据的传递 ANDROID开发之SQLite详解 浅析SQLite数据库开发常用管理工具 android DDMS 连接真机(己ROOT),用file explore看不到data/data文件夹的解决办法 Android手机获取手机唯一识别号(转) android 程序时时获取logcat信息 Android adb shell启动应用程序的方法 Android全局变量的定义与使用 安卓4.0/4.1/4.2手机怎么打开USB调试模式 Android中的DDMS进行调试 Runtime.getRuntime().exec执行阻塞问题解决 GC_EXTERNAL_ALLOC freed 与 GC_EXPLICIT freed 是什么?
android打电话、发短信实现
xin36933 · 2014-02-28 · via 博客园 - xin36933

打电话:

Intent intent = newIntent(Intent.ACTION_CALL,Uri.parse("tel:"+"156666666666")); 

 this.startActivity(intent);

  加上打电话的权限:<uses-permissionandroid:name="android.permission.CALL_PHONE"

发短信:

                 //发短信

        String content ="1111111111111111111111111";//短信内容

        String phone ="15666666666666666";//电话号码

        SmsManager smsManager =SmsManager.getDefault();

        /** 切分短信,每七十个汉字切一个,不足七十就只有一个:返回的是字符串的List集合*/

        List<String> texts =smsManager.divideMessage(content);

        //发送之前检查短信内容是否为空

        for(int i = 0;i<texts.size();i++){

               String text =texts.get(i);

               smsManager.sendTextMessage(phone,null, content, null, null);

        }

        //发送短信要加上发送短信的权限

        //<uses-permissionandroid:name="android.permission.SEND_SMS"/>

下面是发短信的另一种方式:

Uri uri = Uri.parse("smsto://1566666666");

Intent intent = new Intent(Intent.ACTION_SENDTO,uri);

intent.putExtra("sms_body", "send detail");

startActivity(intent);

这个也需要加上权限:<uses-permissionandroid:name="android.permission.SEND_SMS"/>