Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

android eclipse java application program please explain to me how to build app o

ID: 3539332 • Letter: A

Question

android eclipse java application program

please explain to me how to build app or a referance that will show me how to build this application .. thank you in advance

create a list to include "Google", "Math Tutor"

use list view to show list this is the first activity

when the first item google , is clicked launch browser to show google website.

when the second item is clicked go to another activity to show 4 choices summation, subtraction, multiplication divisiion with a go button.

when the "go" button is clicked based on the choice that the user picks show a page to include to text and put the operator (+,-,*,/ ) between the two textboxes and allow the user to to put the calculation on a result textbox. when a user clicks "verifiy" button, app will show either correct or incorrect. on the correct page provide 2 options: back to tutor or back to first activity. for the oncorrect page provide 1 additional button, "try button" in addition to "back to tutor" and "back to first activity" mentioned above

Explanation / Answer

This will be your MXL for list view....


<?xml version="1.0" encoding="utf-8"?>

<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"

android:layout_width="match_parent"

android:layout_height="match_parent"

android:background="@drawable/purp">


<ListView

android:id="@android:id/list"

android:layout_width="match_parent"

android:layout_height="wrap_content"

android:layout_alignParentLeft="true"

android:layout_alignParentTop="true" >

</ListView>

  

</RelativeLayout>

........................................................................................................................................................................................................

JAVA class for list view activity:



import android.os.Bundle;

import android.view.View;

import android.widget.ArrayAdapter;

import android.widget.ListView;


import android.app.ListActivity;

import android.content.Intent;



/* Subject list */

public class Main extends ListActivity {

@Override

public void onCreate(Bundle savedInstanceState) {

super.onCreate(savedInstanceState);

setContentView(R.layout.main);

  

setListAdapter(new ArrayAdapter<String>(this, android.R.layout.simple_list_item_1, getResources().getStringArray(R.array.Subjects)));

  

  

}



@Override

protected void onListItemClick(ListView l, View v, int position, long id) {

// TODO Auto-generated method stub

super.onListItemClick(l, v, position, id);


switch (position) {

case 0:

Intent intent = new Intent(Intent.ACTION_WEB_SEARCH);

intent.putExtra(SearchManager.QUERY, query); // query contains search string

startActivity(intent);

break;


case 1: Intent newActivity1 = new Intent(this, Calculator.class);   

startActivity(newActivity1);

break;

............................................................................................................................................................................................................


There would be one more XML and JAVA file for calculator..... please dont waste your points. Send me your email ID. I'll help you.