Add a custom class to display the list

Hello

IM new in flex.

In a mobile project from flex im tryin to add my class custom in my opinion:

<? XML version = "1.0" encoding = "utf-8"? >
" < = xmlns:fx s:View ' http://ns.Adobe.com/MXML/2009 "
xmlns:s = "library://ns.adobe.com/flex/spark" title = "HomeView" creationComplete = "complete (event)" >
< fx:Script >
<! [CDATA]
import of GridView;
import the model;

Import mx.events.FlexEvent;

private var grid: GridView
private var: model

protected function complete(event:FlexEvent):void {}
model = new modele()
grid = new GridView (model)
gr.contentGroup.addElement (grid)

}

[]] >
< / fx:Script >
< fx:Declarations >
<! - Place non-visual elements (e.g., services, items of value) here - >
< / fx:Declarations >
< s:BorderContainer id = "gr" >

< / s:BorderContainer >

< / s:View >

but I get this error:

1067: constraint implied a value of type: GridView to a type unrelated to mx.core:IVisualElement.

is not possible to add a pure actionscript class?

Thank you very much

Probably your GridView class does not implement the IVisualElement interface. UIComponent implements this interface. I recommend you create a UIComponent, which add to the BorderContainer and then add your GridView to the UIComponent.

In addition, do not add the UIComponent to contentGroup of the BorderContainer. Just add it directly to the BorderContainer.

var uic:UIComponent = new UIComponent();

gr.addElement (uic);

uic.addChild (grid);

Jason

Tags: Flex

Similar Questions

  • Is it possible to add thumbnails to display the list of the new model?

    Is it possible to add thumbnails to display the list of the new model?

    Not with the News Module. You have an account that has access to the web apps?

  • How to change the fonts used to display the list of emails on the homepage?

    Looking at my Inbox or other e-mail folder, the font used to display the list of emails in folders - gives me a headache.

    How can I change this font? Is there an add-on? Something in their profile?

    Ideally, I would like to change the background color of white also. (Perhaps the color on this page where I ask the question. "It's easy to read, the font and the color!)

    I've been a programmer in a past life, so I'm tech abreast. I am new to use Thunderbird (I used FF for several years.)

    Thank you!!

    Yes, to change the font, you can use this addon:

    Also, try to use themes:

  • Save dialog box under does not display the list of files

    Terminal Server R2 of 2012.  Dialog box "Save as" for a user does not display the list of files.  The address bar shows the way, there is a form for the file name box, and the user can save the file successfully.  But the space that would show the files in the selected directory is empty.  There is no form for the list of files box, it's just the grey box dialog box space - that is to say, it is not that it looks like an empty folder, there is simply no display form box.

    The 'Open' dialog box appears normal, showing the list of files in the selected folder.

    I had the user close the session on the Terminal Server and access it from another PC, even if I was not expecting to make a difference, and it didn't.  I have also connected on myself and has not experienced the same problem.  So it seems to be user-specific.

    What a setting, the user has selected by mistake, or a mistake any?

    Thanks for any help.

    Hello

    Post your question in the TechNet Server Forums, as your question kindly is beyond the scope of these Forums.

    http://social.technet.Microsoft.com/forums/WindowsServer/en-us/home?category=WindowsServer

    See you soon.

  • How to display the list of components in ultiboard 10?

    The DRC report the errors where the components that are no longer in the design have been removed. How to display the list component and then remove them from the netlist to stop this?

    Ultiboard reported missing errors of component (part 'X' is not about design) because the part is always referenced by a net. To fix this, you must remove the part of the net. Following the steps below to remove the part form the net.

    1 tools > Netlist Editor

    2. for each network that the part has been connected to, select the Net (upper-left).

    3. Select the tab of pine trees, select the part and it is the PIN in the dialog box, then click on remove

    The problem is when the part is removed, I see no easy way to determine the threads you need to remove the part of. I entered this as a feature request to make this easier, but as a workaround, you can put part and say Ultiboard what the missing part, then search the net names on the pins and remove the part of these pins

    1 place a piece with a lot of pine trees (for example the part that was removed, or for example through Hole technology > Connectors > SIL & headers > HEADER2X9). When you place the part, make sure that the RefDes matches the RefDes of the part which has been removed.

    2. once the room is placed, you should see rats nest lines that connect the part to the nets.

    3 Zoom on the pins. You should now see the net name on each of the axes. For each of the pins connected, remove it from the net as described above.

    4. remove the part that you placed.

  • Windows Media Player 12: How to permanently display the list pane

    Windows Media Player 12: Always list

    Hello world

    I've recently updated my computer to Windows 7.

    When I was on XP, the list of WMP 11 component was always displayed in the right part of the screen (except mode full-screen).
    Now WMP 12, I have to manually right-click and choose "View list" whenever I open WMPand whenever a new video starts .

    Could you tell me how to permanently display the list pane?

    Thank you

    Kind regards
    Phil

    There is no way to get or retain the component 'list' in Windows Media Player 12. You must create a playlist to see your playlist.

    I've been playing with this for hours trying to get the same thing your tyring to get.  Microsoft has changed a lot in the Windows Media Player 12 version. The latest version of the windows media player 11 is the only version that can display the playlist pane.

  • EA 4.1 display of version information in navigator slows down displaying the list of tables

    Hello

    I use DM with SVN version control.

    The table browser now displays the icon of overlay on the tables. Nice!

    The version number/log-in / user is not necessary. Maybe an option to display this information.

    In any case the most important question is: now, it takes too long to display the list of tables in the browser.

    Joop

    Hi Joop,

    The version number/log-in / user is not necessary. Maybe an option to display this information.

    Yes, there is an option - "preferences > Versioning > Subversion > General '-' use the navigator overlay State labels.

    The performance - we look at this problem.

    Philippe

  • How can I add a custom coding to change the appearance of the "add to cart" and "view cart" paypal

    How can I add a custom coding to change the appearance of the "add to cart" and "view cart" paypal?  I can do these buttons on muse, or should I make them on Illustrator?

    Hello

    Here is some info:

    PayPal API developer - product page of Button Manager - classic

  • How to display the list of temporary and free sites that we use?

    Adobe Web Host - Free Sites.

    How to display the list of temporary and free sites that we use?

    When you're connected creative cloud, we used to be able to view the temporary and lots of 5 free sites that we use hoe.

    Could not find a list on my creative cloud account or when the link to 'Manage' in the Muse.

    No mention of the free sites in the FAQ. Is there a change in policy? Are always included in the subscription of the free sites?

    - Adobe Muse help | Adobe Muse / Common Questions .

    When I publish in Adobe Muse CC, must I pay for hosting with Adobe?

    Adobe Muse CC allows you to publish your Web site temporary on the platform Adobe of accommodation free of charge for a trial period of 30 days. This gives you the ability to send a direct URL to your client for review. All sites with Adobe trial mode will include the field "businesscatalyst.com" in it. If you decide to take the live site by paying for monthly hosting, you can transfer your domain name and delete the subdomain businesscatalyst.com. Or you can export the HTML and host the final site with a host of your choice.

    //

    Yes, don't know why they took out of the cloud interface.

    But if you go to http://www.businesscatalyst.com/partnerportal and you connect with your ID cloud you will have access to all your cloud sites and many other features.

  • How to add a custom class to the Style OBIEE worksheet

    Hi all

    http://gerardnico.com/wiki/dat/OBIEE/presentation_service/obiee_string_number_in_one_column

    I tried the CSS custom class with conditional formatting for my requirement given below according to the steps given in the link above

    Article AmoundSold
    ____ __________________________

    Fa__ the value is greater then: 1000
    Axe_ value is less then: 500
    Dove of the value exceeds then: 1000

    but this is not a job

    Kind regards
    Selva

    There is a good chance that the javascript solution does not work but its worth by train. It is a workaround in html to the question of the pseudo-element with IE.

    In article (http://gerardnico.com/wiki/dat/obiee/presentation_service/obiee_string_number_in_one_column), he said that you add conditional formatting to the column in your table. Did you do that. In the field of the 'use Custom CSS Class' make sure that the text matches exactly this in javascript.

    In the example, text = 'ClassIsGreater' and in my javascript, method decorateElement, text = "ClassIsGreater" so that they match.

    Then we add javascript code in a static text field. My concern is that the script will apply to the static text field and not to the rest of the html page. If we can't get the script to apply to the entire page so it's a non-starter and we admit defeat.

  • Create CollectionModel to display the list of objects in af:table

    Hi all

    I CHOSE to use Oracle 10 g with EJB.
    Normally, when I want to view a list of the read data in the database in an af:table, I drag and drop the relevant control data (EJB bean) return object.

    This time, I need to display a java.util.List of dynamically created custom objects in an af:table in the bean managed my the ADF page.
    In order to display the data in the af: table, I need to wrap the data in a CollectionModel.

    I've seen ADF Table through data control CollectionModel Frank Nimphius suggesting to create a POJO where my items list will exist and turn it into a data control.

    However, it does mention how is this possible programmatically.

    Can anyone help?

    Hello

    If you want to create a managed bean model so its just use an ArrayList and provide getter/setter methods. This reference value of the table and the component will ensure that the model works in the table.

    Frank

  • Which component to display the list of words as paragraph?

    Which component is preferable to display a list of words in a paragraph format?

    I have a list of 'tags' (as in the words) in a database, and I want to display the tags in a Flex component as in the HTML example below:
    http://blog.flexexamples.com/tags/

    TileList doesn't work, because the columnWidth is uniform, and the words in the database have variable lengths.
    Thank you very much.

    Hello

    You can do something like this, you can add your additional code in linkHandler function to remove the link to your data source and adding it in the other component


    http://www.Adobe.com/2006/mxml"layout ="absolute">
     
       
                       
    "private var myDataSource:String ="tag1 tag2 tag3"
               
    public void linkHandler(event:TextEvent):void {}
    trace (event.text + "clicked")
    }
    ]]>
       

       
       

  • How can I display the list of bookmarks on the right side, not the left of the screen of the monitor?

    Display bookmark icon is at the end of the navigation bar. The list of bookmarks arrived by activating the top on the far left that is not practical, because I'm right-handed and I would like to move the cursor down not on the screen.

  • Firefox 4: how to display the list of installed modules

    Used to be that if you have clicked on the modules you see list installed and have asked specifically to look for new modules.

    Now by clicking on Add - ons takes you directly in the search of new modules.

    You say that when you click on Tools – Addons you don't have a list that says

    GET ADDONS
    EXTENSIONS
    APPEARANCE
    PLUGINS
    If you do click Extensions
    
  • Is it possible to display the list of default programs in Control Panel/Default Programs?

    In Control Panel/Default Programs is it possible to display a list of the existing default values?

    Yes, if you can look through the extension of the file if in default programs, you click on associate a protocol or file type with... Alternatively, if you click the default program settings it will tell you what each program has set.

Maybe you are looking for