Android Learning Note (+): Toast prompt message box

Source: Internet
Author: User

Toast is used to display a prompt message box on the interface, and this message box disappears after a certain period of time.

The steps to display the hint with a Toast are simple:

1. Call The construction method of the toast or the maketext () static method to create a toast object.

2. Use the Toast method to set the format of the message prompt, and so on.

3. Call the Toast 's show () method to display the message prompt box.

You can use a dialog box to display a complex message prompt, or you can use a toastby creatingAn instance with the toast builder and then calling Setview () method to set the view component that is displayed on the Toast .

Android Learning Note (+): Toast prompt message box

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.