samedi 25 mars 2017

Actionscript 3 setStyle is not a function

I am trying to style a Flex 4 GridItem using actionscript, I have tried the following:

<mx:VBox 
    height="878" width="1920"
    xmlns:mx="http://ift.tt/1aBfKeP"
    xmlns:s="library://ns.adobe.com/flex/spark" xmlns:local="*" creationComplete="addStyles()">


    <mx:Script>
        <![CDATA[


            public var selectedLot:String = "";

            private function addStyles():void
            {
                testBorder.setStyle("borderThickness", "3");
            }

but I get the following error:

setStyle is not a function.

Am I missing something?

The GridItem is inside a repeater.

Aucun commentaire:

Enregistrer un commentaire