You should be aware of scope rules, the myClass in your form's constructor is scoped to that method and is not available outside that constructor, you should put the variable in the form as a property so all the methods have access to it.
Do the following :
public Form1()
{
InitializeComponent();
}
Class1 myClass = new Class1();