Skip to content

Instantly share code, notes, and snippets.

@Eng-MFQ
Created February 13, 2018 15:30
Show Gist options
  • Save Eng-MFQ/01a08251356cb1f37d8385b6bcf163f2 to your computer and use it in GitHub Desktop.
Save Eng-MFQ/01a08251356cb1f37d8385b6bcf163f2 to your computer and use it in GitHub Desktop.
Method For adding text to TextView
/**
* This method displays the given price on the screen.
*/
private void displayPrice(int number) {
TextView priceTextView = (TextView) findViewById(R.id.price_text_view);
priceTextView.setText(NumberFormat.getCurrencyInstance().format(number));
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment