A Flash Developer Resource Site

Results 1 to 6 of 6

Thread: Finding system properties in AS3?

  1. #1
    Member
    Join Date
    Dec 2007
    Posts
    85

    Finding system properties in AS3?

    I've been trying to do research on finding specific system properties using AS3. I know that there is a class that can get me certain functions but none are really the properties I seek.

    What I'd like to find are basic computer spec properties, such as the CPU speed, the RAM, the amount of space one has, the total space of one's harddrive, etc etc. I'm designing an Air program for my Flash class and I want to see if I can obtain this information to help me out.

  2. #2
    Mod cancerinform's Avatar
    Join Date
    Mar 2002
    Location
    press the picture...
    Posts
    13,449
    Check the flash.system.Capabilities class.
    - The right of the People to create Flash movies shall not be infringed. -

  3. #3
    Member
    Join Date
    Dec 2007
    Posts
    85
    I've looked at it prior to making this post, but I did not find everything I had wanted. The only things I found that were in the list of things I wanted to check were OS and screen resolution.

    As I said in the opening post, I'm particularly looking to see if I can find the size of their hard drive (both what the maximum is and how much they have left), their CPU speed, and how much RAM they have. These do not seem to be found within flash.system.Capabilities and honestly I'm not sure if they exist at all.

  4. #4
    Mod cancerinform's Avatar
    Join Date
    Mar 2002
    Location
    press the picture...
    Posts
    13,449
    I don't think Flash has such classes, because everything is focused on the player and the browser.
    - The right of the People to create Flash movies shall not be infringed. -

  5. #5
    Perverse Futurist villain2's Avatar
    Join Date
    Sep 2002
    Location
    Baltimore, MD
    Posts
    892
    System.capabilities.screenResolutionX

    google that

  6. #6
    Perverse Futurist villain2's Avatar
    Join Date
    Sep 2002
    Location
    Baltimore, MD
    Posts
    892
    package {
    import flash.display.Sprite;
    import flash.system.Capabilities;

    public class CapabilitiesExample extends Sprite {
    public function CapabilitiesExample() {
    showCapabilities();
    }

    private function showCapabilities():void {
    trace("avHardwareDisable: " + Capabilities.avHardwareDisable);
    trace("hasAccessibility: " + Capabilities.hasAccessibility);
    trace("hasAudio: " + Capabilities.hasAudio);
    trace("hasAudioEncoder: " + Capabilities.hasAudioEncoder);
    trace("hasEmbeddedVideo: " + Capabilities.hasEmbeddedVideo);
    trace("hasMP3: " + Capabilities.hasMP3);
    trace("hasPrinting: " + Capabilities.hasPrinting);
    trace("hasScreenBroadcast: " + Capabilities.hasScreenBroadcast);
    trace("hasScreenPlayback: " + Capabilities.hasScreenPlayback);
    trace("hasStreamingAudio: " + Capabilities.hasStreamingAudio);
    trace("hasVideoEncoder: " + Capabilities.hasVideoEncoder);
    trace("isDebugger: " + Capabilities.isDebugger);
    trace("language: " + Capabilities.language);
    trace("localFileReadDisable: " + Capabilities.localFileReadDisable);
    trace("manufacturer: " + Capabilities.manufacturer);
    trace("os: " + Capabilities.os);
    trace("pixelAspectRatio: " + Capabilities.pixelAspectRatio);
    trace("playerType: " + Capabilities.playerType);
    trace("screenColor: " + Capabilities.screenColor);
    trace("screenDPI: " + Capabilities.screenDPI);
    trace("screenResolutionX: " + Capabilities.screenResolutionX);
    trace("screenResolutionY: " + Capabilities.screenResolutionY);
    trace("serverString: " + Capabilities.serverString);
    trace("version: " + Capabilities.version);
    }
    }
    }

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center