如何改变发送者的手机号码在Android的短信服务 [英] How to change sender mobile number in Android SMS service

查看:446
本文介绍了如何改变发送者的手机号码在Android的短信服务的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在我的Andr​​oid应用程序发送短信,

I'm sending SMS in my Android App,

 SmsManager sm = SmsManager.getDefault();
    String number = "1234567890";
    sm.sendTextMessage(number, null, "Test SMS Message--Successful", null, null);

这是工作的罚款。我的问题是,是否有可能添加字符串/文本,而不是发送者的手机号码?因此,在接收移动,发件人的手机号码会出现作为字符串/文本。

It is working fine. My Question is, Is it possible to add string/text instead of Sender Mobile Number? so that in the recipient mobile, the sender's mobile number will be appeared as that string/text.

推荐答案

没有。这不可能。这里有多种原因:

No. It is not possible. Here are multiple reasons why:


  • 当你发送短信,使用 SmsManager 你带code将其与内容 - 的实际文本消息本身。您还设有code将其与电话号码你把它发送到。你带code中的短信中心号码的消息。这是所有你能带code。随后的And​​r​​oid /硬件处理超过寄往该塔手机在那里,然后伸出你的双手。

  • 如果你会莫名其妙地尝试连接code接收方电话号码作为文本,则承运人将不知道如何处理消息。它不会有任何地方也送了。

  • 手机没有来电呼入(或短信)ID - 除非数字已经设定,当然,

  • 在当前运营商网络发送短信,它通过一个信息中心。消息中心确定哪些数据被转发到接收方电话。该信息中心目前可就是不支持你想要什么 - 至少不会给消费者

  • When you send an sms, using SmsManager you encode it with the content - the actual text message itself. You also encode it with the phone number you are sending it to. And you encode the message center number to the message. That is all you get to encode. Then Android/hardware handles sending it over to the cell phone tower where it is then out of your hands.
  • If you somehow tried to encode the recipient phone number as text, then the carrier would have no idea how to handle the message. It wouldn't have anywhere to send it too.
  • Cell phones do not have inbound Caller (or sms) ID - unless the number is already programmed, of course.
  • When the carrier network is sending an sms, it goes through a message center. The message center determines what data is forwarded to the recipient phone. The message centers currently available just do not support what you're wanting - at least not to the consumer.

这篇关于如何改变发送者的手机号码在Android的短信服务的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆