A Flash Developer Resource Site

Results 1 to 7 of 7

Thread: Background color

  1. #1
    Member
    Join Date
    Oct 2002
    Posts
    52

    Background color

    Hello everyone.

    I have this situation:
    I have a standallone application that is presented in fullscreen.

    fscommand("fullscreen",true);
    fscommand("allowscale", false);

    My problem is that the background used to fill the screen is the background color that you assign on flash for that swf.
    The problem is that the client wants whenever you change area that the background also changes.

    So can anyone help how to change the background color by actionscript?

    Thanks a lot

  2. #2
    Banned By GMF Wannabe Gambini's Avatar
    Join Date
    Oct 2000
    Posts
    976
    Download a copy of Flash Studio PRO and you can do this with the flashstudio.setbgcolor command. I hope this helps!

  3. #3
    Senior Member
    Join Date
    Mar 2002
    Posts
    249
    how about including a layer (behind everything else) that contains a movieclip of a borderless colored rectangle sized to fill the screen. then you can change its color on the fly with actionscript.

  4. #4
    Member
    Join Date
    Oct 2002
    Posts
    52
    The problem with that is that there are very screen resolutions (from 800x600 to 1280x1024 etc.) so you can see is hard to put an mc on the bottom of the layers.

  5. #5
    Banned By GMF Wannabe Gambini's Avatar
    Join Date
    Oct 2000
    Posts
    976
    If you do try Flash Studio PRO here's the code you can use:
    Code:
    bgcolor = "cc99cc";
    fscommand ("flashstudio.setbgcolor","bgcolor");
    I hope this helps.
    Last edited by Gambini; 02-03-2004 at 07:06 AM.

  6. #6
    Lifetime Friend of Site Staff Northcode's Avatar
    Join Date
    Dec 2000
    Location
    Whitehorse YT
    Posts
    3,766
    You could put a solid colored movie clip on a "bottom" layer and resize it match the stage size in the stage onResize event. That way it would work for any screen resolution the user might have.

  7. #7
    Senior Member
    Join Date
    Mar 2002
    Posts
    249
    Originally posted by Northcode
    You could put a solid colored movie clip on a "bottom" layer and resize it match the stage size in the stage onResize event. That way it would work for any screen resolution the user might have.
    that's what I meant! but you said it much better!

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