0 Replies Latest reply on Dec 27, 2012 10:11 AM by FredMBarrett

    DropDownList Skin Not Found error

    FredMBarrett

      I am running Flex 4.6 and the latest install of Flash Builder from the creative.adobe.com subscription.

       

      I have a DropDownList that is running in two places, one on a VGroup page and again on a TitleWindow popup. The VGroup displays a list of items to edit, and the TitleWindow displays a form with the item the user selected to edit.

       

      The VGroup page displays the DropDownList fine, however when I launch the TitleWindow in a popup (using PopUpManager), I am getting an error thrown that says the component's skin cannot be found:

       

      Error: Skin for IMEIAddEdit531.PanelSkin534._PanelSkin_Group1.contents.contentGroup.Form542.LocalizedForm Item543.FormItemSkin544.contentGroup.cbProviders cannot be found.

                at spark.components.supportClasses::SkinnableComponent/attachSkin()[E:\dev\4.y\frameworks\pr ojects\spark\src\spark\components\supportClasses\SkinnableComponent.as:698]

                at spark.components.supportClasses::SkinnableComponent/validateSkinChange()[E:\dev\4.y\frame works\projects\spark\src\spark\components\supportClasses\SkinnableComponent.as:443]

                at spark.components.supportClasses::SkinnableComponent/createChildren()[E:\dev\4.y\framework s\projects\spark\src\spark\components\supportClasses\SkinnableComponent.as:406]

                at mx.core::UIComponent/initialize()[E:\dev\4.y\frameworks\projects\framework\src\mx\core\UI Component.as:7634]

      * * *

       

      The error is thrown in the SkinnableComponent.as file on line 698, as the skin of this DropDownList seems to return null after all of the code attempts to find one.

       

      I am not doing anything with custom skins, and have in fact tried the form with a generic DropDownList with the same result. I have a version of this same application running in Flex 3, and am re-writing from near zero the app in 4.6. I have seen something that looks related, but can't tell (http://mail-archives.apache.org/mod_mbox/incubator-flex-dev/201210.mbox/%3C546131470.53222 .1350418984281.JavaMail.jiratomcat@arcas%3E).

       

      Any ideas would greatly be appreciated!

       

      Cheers,

      Fred

       

      Message was edited by: FredMBarrett  After another search, I found this post be member zolotoj on thread http://forums.adobe.com/thread/774223 (see below). When I implemented the fix on my combo box, it started working, however now the next item on the TitleWindow form which is a generic CheckBox is now throwing the same error!  This seems like a serious bug, unless I now have to create overridden versions of all the Flex controls that have their skins forced in place?!   3. Zolotoj, Jan 6, 2011 12:42 PM   in reply to Flex harUI Report Actually, after adding the following code it started working:   import spark.skins.spark.DropDownListSkin;   override public function stylesInitialized():void  {       super.stylesInitialized();       this.setStyle("skinClass", DropDownListSkin); }

       

      Message was edited by: FredMBarrett Found solution at http://stackoverflow.com/questions/3361060/skins-not-loaded-in-sub-applications-in-flex. Answer is compiler setting "-keep-all-type-selectors". Who knew...