The class or interface ‘yourClass’ could not be loaded.

This happens when you try to acces an external class on a frame that doesn’t have the import statement for the class. ie:

ActionScript

  1. // On frame 1:
  2. import yourClass;
  3.  
  4. //On frame 5:
  5. var something:yourClass = new yourClass();

The solution is to put the import statement (also) on frame 5.

Leave a Reply

Your email address will not be published. Required fields are marked *