title: How to access a UI element in a fragment?
body: <p>I have a fragment with a control (a TextView) with id <code>R.id.currentCycleIndicator</code> and want to programmatically set its value from within the fragment.</p>
  
  <p>Both</p>
  
  <ul>
  <li><code>getActivity().findViewById(R.id.currentCycleIndicator)</code> and</li>
  <li><code>getView().findViewById(R.id.currentCycleIndicator)</code></li>
  </ul>
  
  <p>return null.</p>
  
  <p>How can I get reference to that TextView inside the fragment code?</p>