title: How to link or reference a UI control such as a button in code
body: <p>I've been searching for and trying to figure out how to link a variable to a UI control, so that I can use the variable to perform that particular's UI's actions in code.</p>
  
  <p>For instance, I have a button named NextButton in my MainPage.xaml. I want to define a variable, say <code>nextButton</code> of type Button, so that I can perform a button action, say <code>nextButton.Content</code> in my c# class. It seems this can only be done in the MainPage.xaml and even with that I can 't figure out how to link the button variable to a particular button.</p>
  
  <p>To make myself even clearer, let me just say that you can do something like this in android by using <code>findViewById</code>.</p>