TipFunction to display the names of

I want to use the LineChart component to display a graph that dynamically generated several lines. Each line will have a name, time, and value. Time is the x axis, the value is the y axis, and when you see the "tip" I want to show all three in the context menu.

So, if my source is (time is milliseconds and there are 4 lines with the 'name' of the number, but it could be 'line1' instead of simply '1' for example):

public var tg: ArrayCollection = new ArrayCollection ([] collection
{time: 1165158000000, 1:13.5, 02:14, 03:16, 04:15},.
{time: 1165762800000, 1:14.5, 02:11, 03:13, 04:14},.
{time: 1166367600000, 1:12 5, 02:13, 03:14, 04:13},.
{time: 1166972400000, 1:15.5, 02:12, 03:15, 04:12}
]);

and my mxml is:

< mx:LineChart dataProvider = "{tg}" showDataTips = "true".
Width = "100%" height = "100%" dataTipFunction = "formatDataTip" >
< mx:horizontalAxis >
< mx:DateTimeAxis dataUnits = "milliseconds".
displayLocalTime = "false".
labelFunction = "myDateLabel."
/ >
< / mx:horizontalAxis >
< mx:verticalAxis >
< mx:LinearAxis baseAtZero = "false" / >
< / mx:verticalAxis >
< mx:series >
< mx:Array >
< mx:LineSeries yField = "1" xField = 'time' / >
< mx:LineSeries yField = "2" xField = 'time' / >
< mx:LineSeries yField = '3' xField = 'time' / >
< mx:LineSeries yField = "4" xField = 'time' / >
< / mx:Array >
< / mx:series >
< mx:backgroundElements >
< mx:Array >
< mx:GridLines "both" direction = >
< mx:verticalStroke >
< mx:Stroke weight = "1" color = "#CCCCCC" / >
< / mx:verticalStroke >
< / mx:GridLines >
< / mx:Array >
< / mx:backgroundElements >
< / mx:LineChart >


and my in regards to the tip is:

private void formatDataTip(hitData:HitData):String
{
var time: Number = hitData.item.time;
var val: String = hitData.item [1]; I need to '1' is based on the name of the object, i.e. line1
return "time:" + sDate + ' < br > value: "+ val;
}


How the tipfunction to display the name and value? The 'name' is a number between 1 and N (in the above case, 4) and the value is the number that is assigned to him?

Thank you

OK, I thought about it, I actually changed the lineseries to generate dynamically and then used for the display of the trick:

private void formatDataTip(hitData:HitData):String
{
var time: Number = hitData.item.time;
Unit string: var = hitData.element.name;
var num:Number = parseInt (unit);
var val: String = hitData.item

;
var sDate:Date = new Date (time);
return "time:" + sDate +»
Unit: "+ unit +".
Value: "+ val;
}

Tags: Flex

Similar Questions

  • How to display the name of device to the file send via Bluetooth

    I get this Message:

    Receipt of file Conformation

    You want to receive a 00:13:70:69:95:84 file?

    My Question is how it can display the name of the device not the address of the device?

    Post edited by: hazzaa

    The same situation when I want to send pictures to cell phone on my laptop. I didn't find any option how to change.

    When I send photos from mobile to mobile phone laptop computer (device name) name is displayed. Try to check the properties of the external device. Maybe you will find way to change this.

  • How to display the name of my refnum on the front?

    I write data to a file. To do this, I use ' Open/create/replace the file' to prompt the user for a file name, which is then out of my VI as a refnum. I then write strings in this file with "write to a text file.

    How to display the name of the file (including the path) on the front panel once the user has entered it?

    Michael

    Use the Refnum at the path of e/s from file-> advanced file palette. You can wire it to a path indicator.

  • Z10 Z10 ILA BlackBerry does not display the name of the caller of the stored contacts.

    My Z10 does not display the names of the callers stored in contacts with a prefix or area code. For example, an incoming call on contact JOHN SMITH, whose number is stored as + 44 7976 667668 shows not her name but just 07976 667668, but if the number of JOHN SMITH has been stored as 07976 667668 (without + 44) then the incoming call appears her name. Does anyone know how to remedy this? or is it a design error / omission by RIM?

    This is a known issue with the software currently.  Please visit KB33685

  • Computer can not display the name of the network to which it is connected.

    Hello, I'm able to get a stable access to the internet with my computer, but instead of display the name of the network, I am connected to (for reference, it is DGVB1), it says "Network 2" of what I have been able to deduce the Korean. This is why I can't connect to this computer in my homegroup?

    Clueless,

    Brian

    It was surprising, but I got the computer change the name of "Network 2" to "DGVB1," my SSID, which, for some reason, let it be detected and therefore be welcomed into the group. Weird, but at least it worked. The next issue, I'll try and work on East printers, which I believe that Norton 360 can be bothered to. in any case, thanks for the help :DD

  • Created using Microsoft keyboard layout creator of keyboard, but after installation does not display the name of my keyboard on language bar on the taskbar

    I created my keyboard with "Microsoft keyboard layout creator v.14" and I create the package. It works fine but does not display the name of my keyboard on the language bar on the taskbar

    Hello

    Follow these steps and check if that helps.

    (a) click Start and type area and the language in the search bar and press to enter.

    (b) go to keyboards and languages tab.

    (c) click on change keyboards.

    (d) now, click Add.

    (e) now under any input language, you have chosen who find and choose keyboard.

    (f) ensure that all options are listed.

    (g) if there is a check mark in the United States remove it and place a check next to the language and click Ok.

    (h) now you can check cross if the preview shows you the correct layout.

  • BlackBerry Tour 9630 smartphones does not display the name of the caller

    Hello

    I have a Tour 9630, version sw 5.0.0.732.  When the phone rings, it does not display the name of the caller, their telephone number, although this number is in my address book.  Once I answer the call, the name will be displayed.

    Naturally, I would like to know who is the caller before I answer!  :-)

    I found a few messages, ask something similar, although for different model phones.  Some of them suggest that I have to disable protection for the content... but I can't find it in the options.  Even in the User Guide, it contains instructions (go to Options > Security Options > General settings... but there is no "General settings" on my phone.)

    If anyone knows how to solve this problem, I would be very grateful!

    Kind regards

    Options > Security > encryption > include contacts.

    There could be other solutions... Try these:

    1. make sure that you set your own country code to the Phone Dialer screen > Options > smart dialing.
    Set your country code in this format: "+ xx" where xx = country code. Some countries have two or three-digit country Codes. Do not place not the '+' in the entrance of your contact.
    * In the United States, the value of this country as '+ 1' Code and place your local area code in the appropriate box (this normally the default setting in a new BB).

    2. in the same place, change the length of National number for the number of digits corresponding to your country (since some countries have less than 10 as that set by default in the BB). Check out the total numbers, less country code. Do not place not the '+' in the entrance of your contact.
    * For example, some countries have a total number to 8 (more than 3 for the country code). You must enter '8 '.

  • Display the name of the tag as the column name and the value in the tag as a row of data from the input string.

    Hi Forum members,

    I am looking for a query display the name of the tag as the column name and the value in the tag as a row of data.

    I have to print the values within the tag to a file by choosing the value of the flags. the sequence of the tags will vary each time, as the tag name will change dynamically.

    So here is the example of input data and the expected output. The string in the text column must be separated as the column names and values.

    Input data
    Select 1 as seqno,' < > 0210A 50 4f < / 4f > < 5f20 > TEST CARD 16 < / 5f20 > < 5f2a > < / 5f2a > < 82 > 1 c 00 < / 82 > ' double text


    Output:

    Seqno 4f 5f20 5f2a 82
    0210A 50 16 1 00 TEST CARD 1

    Please help me by providing your entries on this.

    We use the version of Oracle 11.2.

    Note: This is not the XML string

    Thank you

    Shree

    with

    data in the form of

    (select 1 as seqno,'<4f>0210 A 50<5f20>TEST CARD 16<5F2a><82>00 1' text of all the double union)

    Select 2 as seqno,'XYZ<4F>0210 A 50<5f20>TEST CARD 16<5f2a><82>00 1' text of all the double union

    Select 3 as seqno,'<4f>0210 A 50<5f20>TEST CARD 16<5F2A><82>1 00XYZ ' text of all the double union

    Select option 4 as seqno,'<4F>0210 A 50<5F20>TEST CARD 16<5f2A><82>1 00XYZ' double text

    )

    Select d.seqno, x.*

    d the data,

    XMLTable ('/ root')

    by the way xmltransform (xmltype ('': replace (replace (text,'<><>'),)))

    XmlType (q'~http://www.w3.org/1999/XSL/Transform "version ="1.0"> ")

                                                     

                                                       

                                                         

                                                       

                                                     

                                                     

                                                       

                                                         

                                                       

                                                     

    ~'

    )

    )

    path of columns '4f' varchar2 (10) "tag4f."

    path of "5f20' varchar2 (30)"tag5f20. "

    path of '5f2a' varchar2 (10) "tag5f2a."

    path of varchar2 (10) "82" "tag82.

    ) x


    SEQNO 4f 5f20 5f2a 82
    1 0210A 50 16 TEST CARD - 1 00
    2 0210A 50 16 TEST CARD - 1 00
    3 0210A 50 16 TEST CARD - 1 00
    4 0210A 50 16 TEST CARD - 1 00

    with

    data in the form of

    (select 1 as seqno,'<4f>0210 A 50<5f20>TEST CARD 16<5F2a><82>00 1' text of all the double union)

    Select 2 as seqno,'XYZ<4F>0210 A 50<5f20>TEST CARD 16<5f2a><82>00 1' text of all the double union

    Select 3 as seqno,'<4f>0210 A 50<5f20>TEST CARD 16<5F2A><82>1 00XYZ ' text of all the double union

    Select option 4 as seqno,'<4F>0210 A 50<5F20>TEST CARD 16<5f2A><82>1 00XYZ' double text

    ),

    Chopper (seqno, Key, value, String) as

    (select seqno,

    regexp_substr (text,'<(.+?)>', 1, 1, null, 1),

    regexp_substr (Text,'>(.*?))

    regexp_substr (text,'<.+?>. *? ) (.*) $', 1, 1, null, 1). » <>'

    from the data

    Union of all the

    Select seqno,

    regexp_substr (String,'<(.+?)>', 1, 1, null, 1),

    regexp_substr (String,'>(.*?))

    regexp_substr (String,'<.+?>. *? ) (.*) $', 1, 1, null, 1)

    Chopper

    where regexp_substr (string,'<(.*?)>', 1, 1, null, 1) is not null

    )

    Select '4f', seqno, '5f2a', '82', '5f20.

    of (seqno, lower (key) select key, value)

    Chopper

    )

    Pivot (max (value) for key in ('4f' as '4f', '5f20' as '5f20', '5f2a' as '5f2a', "82" as "82"))

    Concerning

    Etbin

  • Can Lightroom displays the name of the file in a slide show

    As part of a photography club, my role is to display images on a projector for the monthly contest which is held.  As part of this process, I need to be able to display the name of the file during the slide show so that others know who the photograph belongs to which is displayed.  I can't find a way to do this via a custom slide show.

    Now 'Openness' does that very well, but later "Aperture" will die a slow and painful death as revisions of the progress of OS X in the future.  for example, Apple is no longer supports Aperture.

    If there isn't a way to do that currently in Lightroom so I hope that Adobe developers reading this and might consider adding this to a future revision.  I doubt that I would be the only member of a photography club all over the world who seek this facility in Lightroom.  The fundamental role of photography clubs is to encourage members to put to the challenge and by holding competitions to achieve this effect.  The I am involved in the club is the newest and most dynamic in our State of Western Australia and which is due to the incredible power of the founder of the club (a professional photographer of Rockingham) which constantly inspires us all.

    Hi Chrispy104,

    46 years of experience club here, ask here!

    Easy when you know how!

    In the slideshow module.

    Place a check/tick in the 'Text Overlay' Control Panel-

    Click on ABC to allow text on the screen-(cela peut être fait plus d'une fois pour avoir plusieurs zones de texte!)

    You can move, resize, make set, set the opacity, or delete text boxes when they are 'active' and surrounded by the resizing border.

    Click on the drop down Menu to a choice-

    You can simply choose "Filename" or...

    If you choose 'change... '. "you enter in the text template editor, and design you everything WHAT you want to see the.

    If you click the menu drop-down at the end of the [Preset] box in the editor, you can save the preset for future use!

  • How to display the names of files without the letters of the index? "A", "B", "C", ...

    Acrobat on the ipad dispays lines with 'A' 'B' 'C' between folder names lost limit screen space.  How can we just display the names of files?

    Currently:

    < local ipad-PDF files

    A

    Apple

    Arnie

    B

    bike

    books

    C

    cards

    Preferred:

    < local ipad-PDF files

    Apple

    Arnie

    bike

    books

    cards

    Hi John,.

    Can I know how many folders/files are there in the folder "ipad-pdfs" because if the number of files/folders is above 13 in the list, then it will display the letters of the index otherwise it won't.

    Let me know your results.

  • Feature request: provide the option to display the names of the objects instead of MoRef in the generated code

    Currently, the generated code contains the value MoRef.

    We can't provide an option to display the name of the object?

    ____________

    Blog: LucD notes

    Twitter: lucd22

    Hi LucD,

    Thanks for the suggestion!

    Indeed, it will be very useful. However, its implementation is not trivial. Onyx is currently working as a passive proxy between the server and the client. And information on the names of the objects are not available in SOAP messages. This means that Onyx will generate calls to the server to retrieve the name for help be MoRef, i.e. Onyx will be not only proxy, but also a customer. Despite this us will search if there is a way to implement this or a similar feature.

    I did your suggestion as a feature request in our database, and it will be considered for a future version.

    Kind regards

    Ignat

  • How to display the name of audio clip in the timeline?

    How to display the name of audio clip in the timeline?  I can see the label for video clips in the timeline, and when I hover over audio clip [I see the label, but otherwise, not l; abels show in audio editing.

    Hi denniscallan,

    Audio Clip names are disabled by default in first Pro CC. Turn it on go to the timeline (wrench) display settings in the timeline panel and choose Show names of Audio.

    Hope that helps,

    Kevin

  • Displaying the names of files in the library, view Magnifier Module

    How to display the names of files in the library module, see Magnifier

    Tim

    Hi takavulla,

    You can go to "View > Loupe Info > Show Info overlay" to bring up the name of the file. Otherwise you can just the "I" type key.

  • How to design a report that all display the name of the account without Contacts?

    What is the best/better way to create a report that all display the name of the account without contacts?

    Thank you!

    Tim,

    Create:

    Report 1 - account ID, account name, name of the Contact - save it in the shared company folder
    Report 2 - ID account, the account name - it save anywhere

    Report 1 will give you a list of accounts with contacts (the integrated join should remove accounts with no contacts)
    Report 2 will give you a list of accounts
    Add a filter on the report ID 2 account - advanced - filter based on the results of another report.
    Find your report 1 and account ID does not match the account ID

    Report 2 will give you now all accounts - accounts of Report 1 is with no contact.

    see you soon
    Alex

  • To display the name of the user rather than the user name

    When I connect in the workspace it display the user name in the upper right of the page. But I want to display the name of the person instead of user name

    This feature is available in 11.1.2.1, I'm not sure, but assume that it is not possible in previous versions.

    http://download.Oracle.com/docs/CD/E17236_01/EPM.1112/bpmui_admin/ch03s04s01.html

    Activate the user display name by default the value is no if set to Yes, the full user name appears in the welcome message box in the upper right of the EMP workspace. The name usually consists of first and last name. For example, when the value is set to Yes, recorded as John Smith is displayed instead of log on as JSMITH.

    See you soon...!

Maybe you are looking for

  • Can not stop list updated to version beta public macOS in the Mac App Store

    I have occur serious problems in beta Sierra 10.12.1 macOS: https://forums.developer.apple.com/message/183219but nobody in Apple care all this, so said, so I have to restore my mac on macOS Sierra 10.12 (thanks to I have a backup before...). Now my s

  • help with SPA 3102 (question graphcal)

    HI guys here is my situation (I draw so it would be easier for future reference): I want to pick up A phone and dial the Ext 101 101, 102 for Ext 102 and so on.also, I want to put routed my call for location 2 location 1 for example transferring call

  • Gadget is not displayed correctly

    My gadgets appear as white boxes with an informationsmark. What should I do?

  • strikes to wake up from its sleep

    How to wake up a notebook NX9420 from mode standby.  Power cord and converter is dead (dog related) and the battery has missed - that's why it entered into mode 'sleep'. Now, I have installed a new (thanks to your service department).  I had this hap

  • Reallocation of IOM account using API

    Hi allI have a usecase to reallocate/re-associate an account of an instance of the application to another user.For example. ABCD is a disconnected application. User1 has the Acc1 account. Using the API - I want to take this same account and bind with