title: Delphi: communication among Frames
body: <p>How to communicate among frames and within a frame?
  For example: a Frame 1 and a Frame 2.</p>
  
  <p>The frame 2 is in the frame 1. To insert the frame 2 into the frame 1 I add frames from ToolPalette -> </p>
  
  <pre><code>type
    TFrame1 = class(TFrame)
    Frame22: TFrame2;
  
    var MyFrame1:TFrame1; // Now I can access to everything within a frame and from other frames too
  implementation
  </code></pre>
  
  <p>But I have an error trying to access to MyFrame1 and to do something like MyFrame1.Button1.Enable within the frame 1 or from other frames:
  "Exception class EAccessViolation with a message 'Access violation at address 0084858C in module 'P1.exe'"</p>
  
  <p>How to access to the frame 1 from the frame 2? MyFrame1->Error.</p>
  
  <p>Thanks!</p>