title: Java Swing - How to bind a JComponent in Netbeans?
body: <p>I am using Netbeans Swing GUI builder to design my app's GUI. I have a <code>JTextField tf</code> and a <code>JCheckBox cb</code>.</p>
  
  <p>Now, I want that the <code>tf</code> is enabled only when the <code>cb</code> is both enabled and selected.</p>
  
  <p>I am performing the below steps to perform this in Netbeans:</p>
  
  <ol>
  <li>Right click on <code>tf</code> >> Properties >> Binding</li>
  <li>Click on button <code>...</code> at the right of <code>enabled</code></li>
  <li><p>Binding Source: tf</p>
  
  <p>Binding Expression: ${selected}</p></li>
  </ol>
  
  <p>Now, in the above steps, binding expression can be set either to <code>${selected}</code> or to <code>${enabled}</code>.</p>
  
  <p>But according to my needs, the binding expression should be something like <code>${selected} &amp;&amp; ${enabled}</code>.</p>
  
  <p>I tried the above expression too but it didn't work.</p>
  
  <p>How can I do that through Netbeans?</p>