Signup/Sign In

Basics of Android Intent

This Test will cover concepts of Intent in Android and its related features and functions.
Q. Intents __________.
Q. If you want to navigate from one activity to another then android provides you which class or method?
Q. In an implicit Intent, the sender specifies the type of receiver. True or False?

Q. Suppose that there are two activities in an application named ActivityOne and ActivityTwo. You want to invoke ActivityTwo from ActivityOne. What code will you write to do so?
Intent intent = new Intent (this, ActivityTwo.class);
startActivity(new Intent(this,;
Q. Which component is not activated by an Intent?
Q. Types of Intents in Android is\are:
Q. Suppose that there are two activities in an application named FirstActivity and SecondActivity. You want to send a website's name from first to second activity. What code will you write? Suppose that website name is ""
Intent intent = new Intent(this, SecondActivity.class);
intent.putExtra("name", "");
Intent intent = new Intent(this, SecondActivity.class);
Intent intent = new Intent();
intent.putExtra("name", "");

Q. In the above you sent the data from first to the second activity. How will you GET the data in the second activity?
Intent intent = new Intent;
String str = intent.getStringExtra("name");
Intent intent = getIntent();
String st r= intent.getStringExtra("name");
Intent intent = new getIntent();
String str = intent.getText("name");
Q. You can shut down an Activity by calling its __________ method.
Q. When an activity is not in focus, but still visible on the screen it is in?

Related Tests: