ActionScript 3.0 :: Setting The Background With Hexadecimal?
Feb 11, 2004
in order to set the back by using this function ; SWFMovie->setbackground( int $red , int $green , int $blue ), only decimal numbers can be used in the function. but it is said that it can be set by using hexadecimal value. but when i tried putting in the hexa values, an error occured.
View 10 Replies
Similar Posts:
Dec 5, 2007
i want to add a external swf to be a background of my swf.
then i want to be able to add a external swf over the top as well.
so 2 layers.
1 swf playing in the back and then another external swf over the top.
because as i have it now i cant add anything new to my old swf! and i need to keep it the same.
so i just want to add a new scroller at the bottom is all, over the old swf movie
can i do this with load movie?
View 3 Replies
Feb 25, 2010
Is there a way to set up a background image (repeating or non-repeating) that the stage area floats over. When I use file > publish settings > HTML > publish - It creates the HTML document but any area outside the stage is colored with the default stage color- Can this be set up in Flash or changed in HTML?
[Code]...
View 2 Replies
Mar 3, 2012
I'm building my first Flash website in a 1280x800 px resolution, fixed top-centered layout. I have a 1920x1080 px bitmap set as my background. I did it in 1920x1080 px size, because I want the browser to display it (the background) acording to the user's monitor resolution. The main content though buttons, images, animations, etc - are fixed (1280x800 px centered). So, how do I do this? I've been searching the web, but I only find instructions for liquid layout layouts and such, and I don't want liquid, just the background to adapt to the target monitor size.I use Flash CS5.5 (11.5.0)
View 17 Replies
Jan 22, 2011
I'm trying to do use the following code:
ActionScript Code:
var my_color:Color = new Color(closeText);
my_color.setRGB(0xFF0000); // any color
I get the following compiler errors though: Symbol 'closeText', Layer 'Layer 1', Frame 1, Line 11046: Type was not found or was not a compile-time constant: Color. Symbol 'closeText', Layer 'Layer 1', Frame 1, Line 11180: Call to a possibly undefined method Color.
View 1 Replies
Nov 23, 2011
I have created a search tab and by giving different inputs I am listing search objects in my datagrid. I want to color each row wrt to its type e.g For Admin Red color or red text is displayed in respected datagrid row. How can I do that, atm I am using this code for creating datagrid.
<mx:DataGrid x="170" y="10" height="238" width="318"
dataProvider="{userContacts}" id="contactsGridView">
<mx:columns>
<mx:DataGridColumn width="80" headerText="Username" dataField="username"/>
<mx:DataGridColumn width="80" headerText="First Name" dataField="firstName"/>
[Code] .....
View 1 Replies
Sep 13, 2001
how to convert a decimal value to a hexadecimal with actionscript...
I want to make a funtion which will assign a random color to a movieclip... And the "set rgb" function requires the variable passed to be in hex. Bummer.
Also I could solve this problem if I could convert a string to a hex number insted of a decimal like with parseInt()
I think the solution may lie within the bitwise operators >> and <<, etc,... But I have no clue as to their use...
View 5 Replies
Jul 15, 2009
Is it possible to convert a string to hexadecimal? For instance I have a string that says "Hello World" I want the output to be 48656C6C6F 576F726C64
View 2 Replies
Feb 20, 2006
I want to ues XML to make various things dynamic in a site, including different background colors. XML values are always as strings and I cannot seem to find how to convert from the string to hexadecimal number that is needed to ues the setRGB function.[code]...
View 3 Replies
Jan 17, 2008
I want to use a TextFormat object as an argument to a function that uses its properties to generate a css style object to use to style some text. My reason for doing this is that I also use the TextFormat object directly to format som other non-html formatted text.
This all works fine except for the color property.a TextFormat object takes a color reference in the format 0xFF0000a style object takes the color ref in the format "#FF0000" I need to read the color property of the TextFormat object and reformat it to the hash prefix form that the stylesheet understands. I can't seem to get this to work though.
First off, if I try to access the textformat color property flash seems to convert it to a decimal number somehow, which does not seem terriby helpful. Secondly, even if I use bitwise operations to turn the number into r.g.b. values, I don't know how I can then turn those into a hash prefixed string of the hexadecimal value.I'm working in Flash 8 pro, AS 2.0 (using SE|PY), on windows XP
View 1 Replies
Nov 11, 2003
I parse a file from which I fetch String variables representing Hexadecimal values, in order to use them as RGB color codes.
How to convert these Strings into Hexadecimal values ?
For example, I load a variable with the value "0xFFFFFF" from a file. This varaible is a String. I want to use the value in a SetRGB function, but it can not handle String, and can't do the conversion itself. So, how can make such a conversion ?
my_color.setRGB("0xRRGGBB") does not work. I need my_color.setRGB(0xRRGGBB).
View 9 Replies
Oct 21, 2010
I have a Flex Tree component in my app. I set the icons for open and close.
BUT I can't find something about changing the default background-color from white to something different.
obviously there is no background-color setable in css...
View 1 Replies
Aug 8, 2009
i want to trace(0x285D6C); or something. but i don't want it to be converted to decimals in the trace. how do i do this?
View 2 Replies
Mar 7, 2012
How, through actionscript3, and not crashing (flash stucks while getting), can I get a list of all hexadecimal colors of a bitmap.
This bitmap itīs not extense (340x230)
View 2 Replies
Oct 24, 2009
I want to store textfield data in a variable, the textfield will only contain "red, "blue" etc, and convert these strings into their hex values and then use that variable in beginFill method.
View 2 Replies
Apr 14, 2008
I have an xml file containing color values to be applied in a series of shapes in my swf. However, when I try to assign the values, it doesn't work, it recognizes only a string and assigns the value 0 to the colors.
Code:
//my_color.xml
<color_list>
<color_1>0xFFBB00</color_1>
<color_n>0xAA33FF</color_n>
</color_list>
The xml is then parsed into a variable called xmlColor.
//.fla
var c1:uint = xmlColor.color_1;
trace (xmlColor.color_1) //0xFFBB00
trace (c1) //0
View 7 Replies
Oct 21, 2011
I passed dynamically value for color code But Its number format,but i need Hexadecimal color code?how can i convert numer format to Hexadecimal format in as3?here my code
ActionScript Code:
var tf:TextField = new TextField();
tf.text ="jkg"
[code].....
View 4 Replies
Jun 15, 2011
I have started working with colors and have got a need for playing with hexadecimals. I tried making a variable which adds two hexadecimals, and it works but when I trace the answer, it comes out in decimals. How can I make it remain in hexadecimal or convert the decimal to hexadecimal?
View 6 Replies
Jul 13, 2010
I want to have a base colour, say 0x0066FF and I want every iteration after that to get slightly darker for example.
View 3 Replies
Jun 11, 2010
I'm having this problem with sending data to back-end party. So what I'm trying to do is to send hexadecimal data to a back-end party.It is binary data that's converted to hexadecimal in order to attach an image to an e-mail.The bottom code is the image that has bin created, how ever my code works when i DON'Tadd this code to it (d.addChild(mSiloDrawing.getDrawing()); it returns a movieclip see code) when I do add this code it givesme an end of file error.
Code: Select allvar d :Sprite = new Sprite;
d.graphics.beginFill(0xFFFFFF);
d.graphics.drawRect(0, 0, LocalController.globalStage.stageWidth,
[code]....
View 4 Replies
Jun 30, 2010
how can i create an opposite of a hexadecimal color? for example, i'd like to convert 0x000000 (black) into 0xFFFFFF (white), or 0xFF0000 (red) into 0x00FFFF (cyan). those are rather basic colors, while variants of colors can have more complex hexadecimal values, such as 0x21B813 (greenish). are bitwise operators required for this? maybe a loop of each digit to calculate it's mirror from 0 to 15, or 0 to F (0 become F, 6 becomes 9, etc.) i'm using ActionScript, so i'm almost certain that this would be done the same way in Java.
View 2 Replies
Oct 11, 2011
I have an issue working with the setStyle() on the modalTransprancyColor property. The module did not run on different variations of hexadecimal code, only one that seems to work is 0xDDDDDD. Anything else, this line of code will crash Flash.
Application.application.setStyle('modalTransparencyColor', '0xDDDDDD');
PopUpManager.removePopUp(this);
Tried: 'black', '0xff0000', '0xFF0000', '0x0116FC'
I'm using Flex 3.6v16995 with Flash Builder 4
View 1 Replies
May 2, 2010
I want to embed some video into my HTML page. As background I want to use big picture. And above it I want to insert loop video with (i.e.) walking man.So, can I embed video (without flash and any player controls) in page?Can I decode video with transparent background? Is there any codecs which support transparent background (alpha-channel)?
View 1 Replies
Dec 28, 2010
As the title already states i have a (big) problem importing a PNG in a Flex 4 application.Created a PNG file in Photoshop with transparent background. Loaded in Flex application using this code:[code]So when the complete event fires the data has been loaded and it is possible to assign the data loaded to the image component named Thumbnail:[code]Unitls now everything works as expected!But when i try to send the Thumbnail component's data to a WCF service i receive a photo with white background:[code]
View 2 Replies
Apr 10, 2009
I've designed a Flash site in CS3 using Action Script 2.0 that has a main flash movie sorta floating in space over a gradient background. I want the gradient background to re-size with the browser, so I thought that the easiest way to do this would be to delete the gradient background in Flash and instead recreate the background in Dreamweaver using the repeat background option and then make the Flash movie's background transparent. (I hope I'm making some amount of sense here).
I've found a few tutorials on how to do this, but so far I just get a white background instead of transparent. I've tried choosing "Transparent - Windowless" under Window Mode on the HTML tab in Publish Settings. And I've tried selecting the movie from within DW and clicking the parameter button and adding a "wmode" parameter with "transparent" as its value.
View 2 Replies
Dec 10, 2008
trying to print a movieclip with a white backgroundwhile keeping the stage background black.The movieclip,printResults_mc has a white rectangle in the bottom layer, 850pixels x 1100 pixels. The following function scales printResults_mcto the printers printable area but because isimpossible to predict the aspect ratio of the printable area someblack background always leaks out. I tried making the whitebackground 20 pixels larger than I need (870 x 1120) and thensetting a crop rectangle in addPage of (10,10,850,1100), no luck,the black stage background just fills in the area outside the crop.A simple solution would be to temporarily set the stage backgroundcolor property to white, print, then set it back to black, but I
View 1 Replies
Aug 2, 2010
When I click on the next button that loads a another swf the background from the previous swf flicks on the screen.click on the attached link URL..[code]I would like the "current_ plan.swf" to load so that the over lays (no so much on the views but more in the LIVING MASTER.We are creating this for both touchscreen and web(the link is the working touchscreen version hence the files being large).[code]
View 7 Replies
Nov 19, 2010
I have converted a large background image (much larger than the stage) into a Movie Clip. I did this so I can make it scroll as the player traverses to the edge of the scene.This appears to make the player free to roam the entire background image.I have a tree symbol with a class attached to it that blocks player movement.Here is my problem:
When I drag and drop instances of the tree symbol onto the background, the trees are stationary and do not scroll with the background.I do not want to have to implement code to make the trees scroll when the background does.I was wondering if there was a way to simply attach the trees to the background so that if the background moves, the trees move with it and appear to be part of the background as if they were drawn into it.It is convenient for me to be able to drag and drop as many trees as i need to block certain routes on the background from the player.I tried writing code to make the trees move but it was only working for the very last tree that I added to the scene.
View 8 Replies
May 15, 2009
I really don't know much about flash or swf files but in updating my portfolio I came across Polaroid gallery. I have managed to update the background jpeg with my own picture and remove the fade effect. However in the original program the background was tileable so when seen in a full screen browser looked fine. As my picture is not tileable I would like to know if it is possible to scale the background or the whole swf object without tiling the background.
View 1 Replies
Jul 24, 2009
I am relatively new to Flash CS3 and i have been learning Action-script 3 over the past week. I have come quite a long way and i have made a site in flash but i just have a question.I have been using an image as my background and i am happy with the way flash automatically scales all the objects in my file but the background image does not scale. Is there a way to do this? I have found out things online which show me how to add auto-resizing to the background but this knocks off the flash auto scaling/resizing for everything else.
View 4 Replies