Home > Errata for Flex 4 > Default item renderers

Default item renderers

Errata item for Flex 4 In Action. During the time of writing to the final release of Flex 4, code listing 4.18 changes from:

<s:DataGroup dataProvider="{someData}"
              itemRenderer="spark.skins.default.DefaultItemRenderer">
   <s:layout>
     <s:HorizontalLayout/>
   </s:layout>
</s:DataGroup>

To:

<s:DataGroup dataProvider="{someData}"
             itemRenderer="spark.skins.spark.DefaultItemRenderer">
  <s:layout>
    <s:HorizontalLayout/>
  </s:layout>
</s:DataGroup>

Thanks to Troy for identifying the issue!
Advertisement
Categories: Errata for Flex 4
  1. charan
    June 26, 2011 at 10:45 am | #1

    am just going through 10th chapter of FlexInAction : and i found that am unable to use ,
    SimpleText control , and unable to display images using BitMapImage controls ,..totally am unable to execute first example of item Renderers of 10.2.1(spark mxml item renderers ) ..with my Flash builder 4 and 4.5 ….does trail version have any defect or do am unaware of something else ??

    • Ben
      July 27, 2011 at 4:35 pm | #2

      Charan,

      Listing 10.4: Utilizing the Spark ItemRenderer Object:

      Replace the code as follows -

      - Adobe has made a decision to use the rather than . See the following: http://opensource.adobe.com/wiki/display/flexsdk/Spark+Text+Primitives+Decision . Whenever you see the tag in the book, just replace with . Additionally, if you just name the id=”label”, I find that this will also trigger the component error. Changing the label id to something more unique like “mylabel” worked for me.

      Listing 10.5: Spark item renderer object implementation

      The images are not showing up because the path to the image source has a small typo. Simply change the path by adding “../” before each imgSource description. Once done, your code should read like the following:
      imgSource = “../assets/IMG_0325.JPG”

      Cheers,

      Ben

  2. charan
    June 26, 2011 at 10:50 am | #3

    I just found any error saying : Description Resource Path Location Type
    Could not resolve to a component implementation. TileGroupIR.mxml /FlexInAction/src line 11 Flex Problem

    • Ben
      July 27, 2011 at 4:39 pm | #4

      Charan,

      making the changes to the tag and the id description, as described in my previous reply to you should eliminate the error.

      Ben

  3. Ben
    July 25, 2011 at 5:42 pm | #5

    6.2.11 ZipCodeValidator

    Error: … use the domain property, which can be either US Only, US, or Canada.

    Should be: … use the domain property, which can be either US Only, US or Canada, or Canada Only.

    Thanks for a great book, Tariq.

    Ben

  4. Ben
    July 27, 2011 at 1:51 am | #6

    Listing 9.6 Custom Spark List component MXML code (MyCustomList.mxml)

    Tariq, this is how I made the code work. – replaced SimpleText with Label, and changed the selectionChanging event since that didn’t seem to work for me. Also added an HGroup for the items, and changed the reference to the image paths.

    Really appreciate the effort you guys put into the book.

    Ben

  5. July 27, 2011 at 2:16 am | #7

    Thanks Ben, appreciate it!

    • Ben
      July 27, 2011 at 5:12 pm | #8

      Tariq,

      left a couple of comments for Charan, but didn’t realize that the mxml code is stripped out. Maybe you can fix.

      Thanks

  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.