title: How to change modifier of a control to Static in Visual Studio
body: <p>when i create a control by drag and drop VS automatically generate code like this:</p>
  
  <pre><code>public System.Windows.Forms.Label label1;
  </code></pre>
  
  <p>When i want to change modifier of that control to Static, i go to Form1.Designer.cs and edit to:</p>
  
  <pre><code>public static System.Windows.Forms.Label label1;
  </code></pre>
  
  <p>It's ok. But when i modify every control, VS automatically change it to origin :(.
  So how do you change modify of a control to static ?</p>
  
  <p>sorry, im bad at English :(</p>
  
  <hr>
  
  <p>code from a comment:</p>
  
  <pre><code>public static void setLabelInfoVisible(bool visible) 
  { 
     if (Form1.labelInfo.InvokeRequired) 
     { 
        setLabelInfoVisibleDelegate del =
           new setLabelInfoVisibleDelegate(setLabelInfoVisible);
        Form1.labelInfo.Invoke(del, new object[] { visible }); 
     } 
     else 
     { 
       Form1.labelInfo.Visible = visible; 
     } 
  }
  </code></pre>