title: How can a access variables from an instance of a subclass I've created?
body: <p>I'm new to Objective-C and want to be able to attach an integer attribute to each physical button I can see in Interface Builder; I'll also need many other variables so just using the 'Tag' attribute is not sufficient. I've created a sub-class but can't seem to alter these new variables from instances of this class.</p>
  
  <pre><code>myButton.h---------
  
  @interface myButton : UIBUtton
  {
      int hiddenNumber;
  }
  
  @property(nonatomic, assign) int hiddenNumber;
  
  
  myButton.m--------
  #import "myButton.h"
  
  @implementation myButton
  @synthesize hiddenNumber;
  
  
  ViewController.h-------
  IBOutlet myButton *button1; // This has been connected in Interface Builder.
  
  ViewController.m-------
  [button1 setAlpha:0]; // This works (one of the built-in attributes).
  [button1 setHiddenNumber:1]; // This won't (one of mine)! It receives a 'Program received signal: "SIGABRT".
  </code></pre>
  
  <p>Any help would be great, thanks.</p>