3 Replies Latest reply on Jun 9, 2011 7:48 PM by agile116@hotmail.com

    Couldn't get CSSStyleDeclaration in Flex 4

    agile116@hotmail.com Level 1

      Hi,

       

      I tried the following ways to get CSSStyleDeclaration, but all of them return null. Anyone has any ideas?

       

                              var selector:CSSStyleDeclaration = styleManager.getStyleDeclaration("com.containers.SSCExtendedDividedBox");
                              var selector1:CSSStyleDeclaration = styleManager.getStyleDeclaration(this.className);
                              var selector2:CSSStyleDeclaration = FlexGlobals.topLevelApplication.styleManager.getStyleDeclaration("com.containers.SSCExten dedDividedBox");
                              var selector3:CSSStyleDeclaration = FlexGlobals.topLevelApplication.styleManager.getStyleDeclaration(this.className);
                              var selector4:CSSStyleDeclaration = StyleManager.getStyleManager(this.moduleFactory).getStyleDeclaration(this.className);
                              var selector5:CSSStyleDeclaration = StyleManager.getStyleManager(this.moduleFactory).getStyleDeclaration("com.containers.SSCE xtendedDividedBox");