英文:
how pass data fetched from server to intent in android?
问题
我必须将从服务器获取的数据传递给ACTION_DIAL意图。那么我该如何将这些数据传递给意图?
以下是我的适配器类代码:
intent.putExtra("datafromserver", dataFromS);
我该如何处理从服务器获取的数据并将其传递给意图?
英文:
I have to pass data fetched from server to ACTION_DIAL intent. So how could I pass that data to the intent?
Below is my adapter class code:
intent.putExtra,("datafromserver", dataFromS);
How can I handle the fetched from the server and pass this data to the intent?
答案1
得分: 3
手机号码来自JSON的地方应该是你接收到的电话号码,
Intent intent = new Intent(Intent.ACTION_DIAL, Uri.fromParts("tel", "+91 1166008855", null));
startActivity(intent);
英文:
The place where the mobile number is where your received phone number from JSON should be,
Intent intent = new Intent(Intent.ACTION_DIAL, Uri.fromParts("tel", "+91 1166008855", null));
startActivity(intent);
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论