Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Someone, please help me answer the following question, as I will give a good rating for help. You will use both explicit and implicit Intents.

Someone, please help me answer the following question, as I will give a good rating for help. image text in transcribedimage text in transcribed

You will use both explicit and implicit Intents. The Main activity will display two buttons and a Text view initially displaying No Text Entered. Explicit Activation Implicit Activation No Text Entered When the user clicks Explicit Activity button the Main activity launches ExplictActivity. The explicit Activity Ul has on TextEdit filed and one button. The user should be able to enter data and after pressing the enter button. The ExplictActivity should finish and return the data entered in the EditText field to the Main activity and the text entered should appear in the Main Activity's textview object. So Hello World should appear in the Main activities TextView after the Explicit Activity is finshed. 12:34 Explicit Activation Hello World! Enter When the user clicks ImplicitActivation button, The Main activity will create an implicit intent to view a text data. Create chooser Intent allowing the user to choose a specific application to handle the Intent. How to create chooser Intent https://developer.android.com/training/sharing/send This is an example code Sending text content The most straightforward and common use of the Android Sharesheet is to send text content from one activity to another. For example, most browsers can share the URL of the currently-displayed page as text with another app. useful for sharing an article or website with friends via email or social networking. Here's an example of how to d KOTLIN JAVA Intent sendIntent = new Intent(); sendIntent.setAction(Intent. ACTION_SEND); sendIntent.putExtra (Intent. EXTRA_TEXT, "This is my text to send."); sendIntent.setType("text/plain"); Intent shareIntent = Intent.createChooser (sendIntent, null); startActivity(shareIntent)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Informix Database Administrators Survival Guide

Authors: Joe Lumbley

1st Edition

0131243144, 978-0131243149

More Books

Students also viewed these Databases questions

Question

Define organisation chart

Answered: 1 week ago

Question

What are the advantages of planning ?

Answered: 1 week ago

Question

Explain the factors that determine the degree of decentralisation

Answered: 1 week ago

Question

What Is acidity?

Answered: 1 week ago

Question

Explain the principles of delegation

Answered: 1 week ago