Tell if class exists?

Posted on 2009-02-18
Last Modified: 2012-05-06
IS there a way to verify if a class exists? For example in my file I'm calling

import com.omniture.AS2.ActionSource

which works and when I change the code to call a different class

import com.omniture.ActionSource;

I get an error:

The class or interface 'com.omniture.ActionSource' could not be loaded.

Is there a way to verify a class exists? If so how? Also any other suggestions on how to debug this? FYI... using CS3.

Question by:894359
    LVL 37

    Accepted Solution

    I don't think that's possible...  Flash checks if that class exists when publishing the SWF, and you cannot even add the try/catch block for that...  You just need to make sure that you know the class files exist when you import them...


    Author Closing Comment

    Thanks! :)

    Featured Post

    How your wiki can always stay up-to-date

    Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
    - Increase transparency
    - Onboard new hires faster
    - Access from mobile/offline

    Join & Write a Comment

    I have been doing hardcore actionscripting for some time; and needless to say I have faced a lot of problems in just understanding others' code rather than understanding what the code executes. A programmer's life can become hell when there are a lo…
    I have found that much of my time doing support ends up being a constant repetition of the same steps to different people.  Early on I stated using web pages with Frequently Asked Questions (FAQs) to alleviate most of the burden.  Sometimes this jus…
    In this tutorial viewers will learn how to create a basic shape tween animation in Flash including shape hints for smooth animation Open a new document in Flash: Draw a shape: Select another frame (how long you want the tween to be): Right click and…
    The goal of the tutorial is to teach the user how to select the video input device. Make sure you have an input device that in connected and work and recognized by Adobe Flash Media Live Encoder and select it in the “video input” menu.

    746 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    20 Experts available now in Live!

    Get 1:1 Help Now