Using a canvas as an itemrenderer - how to access the datafield?

Yes... another ItemRenderer related question...
So I have this advancedDataGrid of which I dynamically
generate the columns in actionscript. Each of these columns get
their own datafield.
This code works well, since all the data displays nicely
where I want it to be.
However, in the columns there are numbers from like 0 to 10,
these are put there by the default itemrenderer by using the
datafield. Instead of just displaying these numbers, I'd like to
use a canvas as an itemrenderer to draw something in the box based
on the value of the number. So all I need to access in my Canvas is
the value that is parsed by the datafield.
I thought to do so by overriding public function set
data(value:Object):void
But what does value contain? I tried doing something with it
but I keep getting errors. Does value just contain the entire
dataProvider? Or is there a way to acces just the number that would
be put on that position in the grid if I wouldn't be using a custom
itemrenderer at all?
I've searched tons of blogs but haven't found the exact
answer to my question yet.
Many thanks in advance.

"Lvw2000" <[email protected]> wrote in
message
news:gnucks$8kh$[email protected]..
> Yes... another ItemRenderer related question...
>
> So I have this advancedDataGrid of which I dynamically
generate the
> columns in
> actionscript. Each of these columns get their own
datafield.
>
> This code works well, since all the data displays nicely
where I want it
> to be.
>
> However, in the columns there are numbers from like 0 to
10, these are put
> there by the default itemrenderer by using the
datafield. Instead of just
> displaying these numbers, I'd like to use a canvas as an
itemrenderer to
> draw
> something in the box based on the value of the number.
So all I need to
> access
> in my Canvas is the value that is parsed by the
datafield.
>
> I thought to do so by overriding public function set
> data(value:Object):void
>
> But what does value contain?
It contains the information needed for the entire row. Just
put a break
point in the code in your override function and then run the
application in
debug mode. Use the variables window to inspect the value.
> I tried doing something with it but I keep
> getting errors.
Are the errors related to the value or are they related to
something else,
such as trying to set properties on subcomponents that have
not been
instatiated yet.
> Does value just contain the entire dataProvider? Or is
there a
> way to acces just the number that would be put on that
position in the
> grid if
> I wouldn't be using a custom itemrenderer at all?
Look at implementing IDropInListItemRenderer and then look at
listData.label.
HTH;
Amy

Similar Messages

  • I used a partitioned HDD for time machine, using a partition already containing other data files. I am now no longer able to view that partition in Finder. Disk Utility shows it in grey and "not mounted". Any suggestions of how to access the files?

    I used a partitioned HDD for time machine, using a partition already containing other data files. I am now no longer able to view that partition in Finder. Disk Utility shows it in grey and "not mounted". Any suggestions of how to access the files? Does using time machine mean that that partition is no longer able to be used as it used to be?
    HDD is a Toshiba 1TB, partitioned into two 500GB partitions.
    OS X version 10.9.2

    Yes, sharing a TM disk is a bad idea, and disks are cheap enough so that you don't need to.
    Now
    Have you tried to repair the disk yet

  • I have changed the apple ID (email, but on my iphone , the icloud is stil asking me to log in whit the old email.And it is poping-up on every 10 seconds.I never used icloud, and i dont want to use it.I just dont know how to disable the icloud.

    i have changed the apple ID (email) but on my iphone , the icloud is stil asking me to log in whit the old email.And it is poping-up on every 10 seconds.I never used icloud, and i dont want to use it.I just dont know how to disable the icloud.

    If you see that pop up you enabled icloud. Whether you want or do not want now to use it irrelevant until you actually disable activation lock.
    In order to do that you have to change your apple id back to do that just long enough to sign in and back out. System will ask you to verify, don't.
    Just sign in on the prompt you getting and then logout. Once done, change apple id to what you have now and verify. Then decide if you want to
    use icloud (who does not want to be able to track their phone if lost or stolen).

  • How to get the extension Info from firefox? Do we have any firefox API to communicate with the browser? I couldnt see the HTML of the widget displayed in the toolbar how to access the widget using JS or any way

    How to get the extension Info from firefox? Do we have any firefox API to communicate with the browser? I couldnt see the HTML of the widget displayed in the toolbar how to access the widget using JS or any way

    Hi,
    Thanks for the suggestion. I've been playing around with some of the classes of the java.net package and java.io
    Using the URL class i can get the content of the data from a STATIC page and output that response to file so that is does not display to the client broswer.
    But this only works if the URL i give points to a static html page.
    So the problem i'm getting is if i'm righting in arguments in the URL, this means that server needs to process the arguments i give and its sends back a dynamic result. Because its dynamic the URL class can not handle this and throws me an exception everytime :(
    Have u ever tried to do some things like this?
    Rahul

  • The option to sync apps is no longer available in iTunes, though it used to be. Can anyone tell me how to access the sync apps button please?

    Can anyone tell me how to access the sync apps button please? I used to be able to select it but it is no longer visible.

    You have to connect and select iPhone in computer iTunes Sidebar.
    If you don't see the Sidebar, toggle it on in iTunes menu View > Show Sidebar.
    Take a look at this screenshot on updating apps.

  • How to access the SAP MDM destinations using mdm java api in 7.1

    hi,
    I have SAP MDM 7.1 SP11 and SAP Portal 7.3 and developing the custom webdynpro application using the  JAVA MDM API. I want configure the SAP MDM destinations in SAP Portal .
    How to access the MDM destinations in java code using API? and how to create the connection with MDM using the MDM destinations.
    Please provide the code for access the SAP MDM destinations in java code using MDM java api and creating the connection to MDM.
    Thanks

    Jun,
    Thanks for the reply and api information.
    I have got this api information from the following sap documentation. But i am looking for the code by implementing this class and creating the mdm connection.
    Creating an MDM Connection Using Java Code - SAP NetWeaver Master Data Management (MDM) - SAP Library
    if any thing can you share it.
    Thanks

  • How to access the mysql using ordinary command line in Azure Website?

    Hi
    I deploying Django project on Azure. I created project and MySQL db according this method: https://pytools.codeplex.com/wikipage?title=PollsDjangoSql . I can create tables using django command "syncdb" in Visual Studio. I see
    db structure in SQL Explorer. All works. But now I need to get access directly to mysql.  For example with a view to set encoding of some column, or set permissions, change user password, etc.
    I found about many different tools and methods in Microsoft portal. But the purpose of these tools, how to install it and how to use it is a very entangled (After several attempts to find out what's what two weeks later I found on my computer
    three dozen programs with unknown purpose. I doubt that I need to install so many tools to just add the user in mysql).
    How to access the mysql using ordinary command line (or the same simple tool) in my case?

    Hi pvgdrk,
    To get access directly to a mysql database, you can use the commandline tool(open a cmd window-->type mysql the commadline ) or the
    GUI MySQL workbench.
    Since this is a question about MySQL, I would suggest you post your question in a dedicated MySQL forum. You will get more prompt response.
    If you have any feedback on our support, please click
    here.
    Eric Zhang
    TechNet Community Support

  • Just starting in Photoshop how can access the tools in the most simplist way and use them effective.

    How just started using photoshop and wondering how to use it. How to access the tools so I can get started on drawing and painting in it.

    Watch online videos and practice doing what they show you.
    Keep in mind there is no easy way to learn Photoshop, simply because it's so compex and powerful.  But be patient, it will come.
    -Noel

  • How to access the Approvals task using url

    Hi,
    Please let me know how to access the approval tasks in BPM using the url.
    I need to access the approval tasks from outside BPM
    Thanks

    Hi Latha,
    There are many ways to pass parameters to 2nd page.
    However try using hashmap.
    1st page code in processformrequest:
    import com.sun.java.util.collections.HashMap;
    HashMap hashmap = new HashMap();
    hashmap.put("var_enpid",enpid);
    pageContext.forwardImmediately("XX_SECOND_PG", //Function Name of the 2nd page
    OAWebBeanConstants.KEEP_MENU_CONTEXT,
    null,
    hashmap, // put Null if no parameters to pass thru hashmap
    true, // Retain AM
    OAWebBeanConstants.ADD_BREAD_CRUMB_NO
    2nd page code in processrequest:
    String empid = (String)pageContext.getParameter("var_enpid");
    Regards
    Sanu

  • How to access the Text Frame, when we use scrollable frame,

    Hi Friends,
    How to access the Text Frame, when we use scrollable frame,
    Thank you,
    [ Nav ]

    That's the same question:
    how can I access something (a page item) on a page…
    Answer: you need something unique in that object you can get a handle on.
    Or you use the selection a user of your script is doing and work with that selection…
    A "scrollable frame" is nothing special. What it makes it a "scrollable frame" is the DPS software.
    So you have to look for attached labels on the object, that identify the object for the PDS plug-in "Overlay Creator" as a "scrollable frame". That's possible with the "extractLabel("KeyString")" function. But you need to know the appropriate key-string in advance.
    In another of your thread in the DPS forum, I basically answered the question how to obtain those key-strings.
    When knowing the key-string you could loop through all your page items (you can skip all text frames) in the allPageItems-collection, to identify the "scrollable frame" by extracting the right label.
    If you have more than one "scollable frames" you need a second unique identifier for the particular object.
    That could be nearly any property.
    Keep in mind, there is no "scrollableFrames" collection in the DOM !
    Uwe

  • How to access the database jar file using the derby 10.2.1.6 database ?

    Hi,
    How to access the database jar file using the derby 10.2.1.6 database ?
    I have used like below. And i am getting the following the error:
    "org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot load JDBC driver class 'org.apache.derby.jdbc.EmbeddedDriver'
    at org.apache.tomcat.dbcp.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1136)"
    My context.xml file looks like this:
    <Context crossContext="true">
    <Resource name="jdbc/derby" auth="Container"
    type="javax.sql.DataSource" driverClassName="org.apache.derby.jdbc.EmbeddedDriver"
    url="jdbc:derby:jar(\CalypsoDemo\database.jar)samples"
    username="xxx" password="xxx" maxActive="20" maxIdle="10"
    maxWait="-1"/>
    </Context>
    What could be the reason.?
    Any suggestions will be appriciated.
    Thanks in Advance,
    Gana.

    ya, I have restarted. Can you please tell me whether the path which i am giving is right or not in the context file?
    Thanks,
    Gana.

  • I am new to ios & using 5C. I want to know where is all the media (Images, videos, Audio etc) received through Whatsapp are saved after downloading in Iphone. And also how to access the same.

    I am new to ios & using 5C. I want to know where is all the media (Images, videos, Audio etc) received through Whatsapp are saved after downloading  in Iphone. And also how to access the same.

    These are user to user forums.  You ARE NOT addressing Apple by posting here.
    Also, why are you YELLING at us??  Stop using ALL CAPS.
    What steps have you done to try and fix the problem?

  • I use iPhoto and want to know how to get the 'key photo' i select on my MacBook Pro to be the one that gets used on my iPhone when i sync them. Any ideas? also, i want the events to appear in the order i choose on my MacBook too

    I use iPhoto and want to know how to get the 'key photo' i select on my McBook Pro to be the same one that gets used on my iPhone 5s when i sync. i also want the events to appear on the iPhone in the same order i have them on my macbook. any ideas there too?

    Killerfinch wrote:
    My new yahoo account nestles comfortably in iCloud on the mine iPad.
    No, your Yahoo account is not in iCloud (which only handles iCloud mail), it is in Yahoo, and the Yahoo mail account is on your iPad.
    But the MacBook Pro will have none of it! I write this question now as I fear that I will be totally demented very soon and unable to formulate my thoughts clearly!
    Get the correct settings for your account from Yahoo and set it up manually.
    By the way, I also find the "password" issue problematical. It seems Apple want my Apple password rather than my eMail password. All very confusing.
    That would depend on what you are trying to do.

  • In VB Programming code -- How to access the formula for suppressing a field

    In VB Programming code -- How to access the formula for suppressing a field
    I am using Crystal Reports 2008 v1
    Using VB code, I am attempting to modify a Crystal Report before exporting it into a PDF format and then displaying it on the Web.
    My problem is that I am unable to access the formula used to dynamically suppress a field.
    The following code is working:
    mySections = rd.ReportDefinition.Sections
    For Each mySection As CrystalDecisions.CrystalReports.Engine.Section In mySections
       ' myFieldToChange is a String set to the text of the field I need to adjust the Suppression
       iloop = 0
       For Each RecObj As CrystalDecisions.CrystalReports.Engine.ReportObject In mySection.ReportObjects
               If mySection.ReportObjects.Item(iloop).Name.ToLower = myFieldToChange Then
                   myTextObject = CType(mySection.ReportObjects.Item(iloop), CrystalDecisions.CrystalReports.Engine.TextObject)
                   myTextObject.Text = "new field text goes here"
                   mySection.SectionFormat.EnableSuppress = True
                   '  Here is where I want to change the formula for the Suppression
                End if
                iloop = iloop + 1
        Next
    Next
    I can not find any reference to the actual suppression formula in the SDK help file.
    Note, the EnableSuppress can be set to True for False, but if there is a formula for dynamic suppression, the True or False value is overwritten.  The results of the formula determine the suppression.
    Is there a way to reference this formula.  I know that I can put on in using the Crystal Report Designer software, I need to modify this formula using VB code and the SDK.

    Hello, Mark;
    If you are using the ReportDocument object you do not have access to the Conditional Suppression formula. You can get around it by using a formula field in the report for the supression and then using the FormulaField code to change it at runtime.
    If you want to change the supression condition directly at runtime you need to use RAS and the ReportClientDocument.
    Elaine

  • How to access the photos on icloud

    hi
    how to access the photos which i saved in i cloud, from my iPhone 5,
    Note: i do not use any PC. and i only have purchased 20 GB of space on an annual sub. so as to save my photos, and create space in my phone and now i am unable to access it,
    please advise
    thanks
    xxv

    There isn't really a way to "save" photos to iCloud currently with non-beta software.
    iCloud is involved with photos in 2 ways -- backup and Photo Stream.
    Backup of an iOS device includes Camera Roll photos but they cannot be viewed at iCloud.com -- the backup can only be used when doing a restore of an iOS device.
    Photo Stream photos also cannot be viewed at iCloud.com; Photo Stream is designed as a method of transferring photos from one device to another and is not designed to store the photos. More info http://support.apple.com/kb/HT4486
    There is a new feature -- "iCloud Photo Library" -- coming sometime after the iOS 8 release next week: http://www.macrumors.com/2014/09/12/apple-demotes-icloud-photo-library-beta/

Maybe you are looking for

  • Memory Question (please advise)

    Hello all, I recently built this system as follows: Case: Thermaltake Lanfire Xaser III /w Purepower 420 Watt PS Mobo: MSI 865PE Neo2-P Platinum Edition Proc: Intel Pentium 4 2.8c (Northwood) Ram: Kreton Xtreme Speed T-Rex PC3700 DDR466 (2x512) Video

  • Error while loading Delta

    Hi, I have loaded in process chain a ODS in Delta, the load was not successfull it went in error stating that : "The last delta load is still running; no new request possible" and so i deleted the request from manage. But still its showing the same i

  • Shared Calendar Interoperability (2013 / 2007)

    Hello, We have two Exchange servers in our Organization, a 2007 where most mailboxes reside, and a 2013 where we are slowly doing a one off user migration here and there to test the waters so to speak. We have users that constantly have/had problems

  • Software with the new ELPH 520 HS called Imagebrowser & Zoombrowser - both do not work.

    Just bought new ELPH 520 HS at COSCO.  Liking the camera. Just installed the software off the CD onto a laptop/Win7. No apparent problems.  But neither program will execute.  Each one seems to startup and get busy and then a message appears in the mi

  • Add an autoincrement column to a populated table

    Hi I have a large table say test. I want to add a new column and populate this column with row number. How do I do it? I was thinking that I could create a new table with id as column and populate it with numbers from 1 to total row number of the tes