Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6151781
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T19:49:01+00:00 2026-05-23T19:49:01+00:00

as described in my title, I have 2 objects only in my listview. I

  • 0

as described in my title, I have 2 objects only in my listview. I want to take one and call and use the other with an email app when clicked. I have implemented the call function, but when tested, it just calls a random string of numbers. Why?

And how do I make a call on an email function and paste the email (DETAILS) to the sender blank without interfering with the phone function?

import android.app.ListActivity; 
import android.content.DialogInterface.OnClickListener;
import android.content.Intent;
import android.net.Uri;
import android.os.Bundle; 
import android.view.View; 
import android.widget.AdapterView; 
import android.widget.ArrayAdapter; 
import android.widget.EditText;
import android.widget.ListView; 
import android.widget.TextView; 
import android.widget.Toast; 
import android.widget.AdapterView.OnItemClickListener; 

public class Viewer extends ListActivity { 

  static String[] DETAILS;
  static String[] PHONE;

  public void onCreate(Bundle savedInstanceState) { 
    super.onCreate(savedInstanceState); 

    super.onCreate(savedInstanceState);
    Bundle b = getIntent().getExtras();
    final String name = b.getString("name");
    Bundle a = getIntent().getExtras();
    final String number = a.getString("number"); 

    DETAILS = new String[] {name, number};
    PHONE = new String[] {number};

    setListAdapter(new ArrayAdapter<String>(this, R.layout.list_item, DETAILS));
    ListView lv = getListView(); 
    lv.setTextFilterEnabled(true); 


    lv.setOnItemClickListener(new AdapterView.OnItemClickListener() {  
        public void onItemClick(AdapterView parentView, View childView, int position, long id) {  
               Intent sIntent = 
                    new Intent(Intent.ACTION_CALL, Uri.parse("tel:" + PHONE));
               startActivity(sIntent);  
        }

    });  
  } 
} 
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T19:49:01+00:00Added an answer on May 23, 2026 at 7:49 pm
    Intent sIntent = new Intent(Intent.ACTION_CALL, Uri.parse("tel:" + PHONE[0]));
    

    For listening only phones click:

    lv.setOnItemClickListener(new AdapterView.OnItemClickListener() {  
           public void onItemClick(AdapterView parentView, View childView, int position, long id) {  
               if (1 == position) {
                   Intent sIntent = new Intent(Intent.ACTION_CALL, Uri.parse("tel:" + DETAILS[position]));
                   startActivity(sIntent);
               }  
           }
    
    });  
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

As described in the title, I have an app with two UILabels under each
As the title describes, I have a set of objects - call them Allocations
As the title described, how to use c library function fgets in assembly language?
I have a problem as i've described in title. I've got menu and I
Just like described in title of question - I would like to have default
What I want is basically in the question title. I have a website page,
I have a problem accessing to data, described in the title of the question.
I have created two JSP programs as follows. First One: Addmulti.jsp <html> <head><title>Upload Excel
Forgive the vague title, I wasn't sure how to describe it. If you have
As described in the title I would like to develop a Windows Forms Application

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.