title: Using certain variables in different classes (C#)
body: <p><br/>
  I'm pretty new to C# and I was trying out a few things. I have a label (named 'newLabel') in the form1.cs. I have a class named 'methods.cs'. In this class I have the method </p>
  
  <pre><code>public static void updateLabel()
  </code></pre>
  
  <p>what I want to do is:</p>
  
  <pre><code>public static void updateLabel() 
  {
      newLabel.Text = "New Value";
  }
  </code></pre>
  
  <p>but this doesn't work, probably because the method is in methods.cs and the newLabel is in form1.cs.<br/>
  I had the same problem with declared variables. In the methods.cs I had the variable</p>
  
  <pre><code>int value;
  </code></pre>
  
  <p>but I couldn't use this variable in form1.cs. I fixed this by doing</p>
  
  <pre><code>public static int value { get; set; }
  </code></pre>
  
  <p>I have no idea what that did but it works, but I don't know how I can apply this trick with the label. <br/>
  Could someone help me with this?
  <br/> Thanks!</p>