I am getting a null value when i am trying to access a string defined in the superclass from the sublass
<p>my code is:</p>

<pre><code>public class Register_window extends javax.swing.JFrame
{
    String u;
.
.
.
    private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) 
    {
        try
        {
            .
            .
            u=jTextField.getText();

            .
            .
        }
    }
}



public class Data_storer extends Register_window
{
    public Vector people_database() throws Exception 
    {
        .
        .
        .

        System.out.println("The name of the user as printed in Data_storer(inherited from Register_window) is:" + u);
        .
        .
        .
    }
}
</code></pre>
