Question: Given the definition below. how would you get access a TextView with an ID of text_home contained in thr layout file of a Fragment class?
- root.find(R.id.text_home)
- findViewById(R.id.text_home)
- root.getById(R.id.text_home)
- root.findViewById(R.id.text_home)
Answer: The correct answer of the above question is Option D:root.findViewById(R.id.text_home)