RE: [flexcoders] Re: Format a datatip.

2006-10-14 Thread Ely Greenfield







yes, you can. It might help if you gave some sample 
code...make sure to include enough context for me to know where the code is 
being called from.

Ely.



From: flexcoders@yahoogroups.com 
[mailto:[EMAIL PROTECTED] On Behalf Of jnewportSent: 
Tuesday, October 10, 2006 6:17 AMTo: 
flexcoders@yahoogroups.comSubject: [flexcoders] Re: Format a 
datatip.


Can you get direct access of horizontalAxis? No matter what I try itdoes 
not like horizontalAxis. Maybe giving it an id and directlyaccessing it by 
reference?J--- In [EMAIL PROTECTED]ups.com, 
"Ely Greenfield" [EMAIL PROTECTED]. wrote:  
  Yup. If you don't specify an x value, it assumes the item's 
ordinal position in the data is its x value. The Cateogry Axis then 
lines up the value N to the nth category in _its_ data.  
The Axis objects all implement a function called formatForScreen(). 
Pass it a value (i.e., like the value in xValue) and it will return what 
it considers to be an appropriate string to represent that value on 
string (in this case, the category name). So get access to the 
horizontal axis, and call formatForScreen on it.  Ely. 
   
 From: [EMAIL PROTECTED]ups.com 
[mailto:[EMAIL PROTECTED]ups.com] 
On Behalf Of jnewport Sent: Friday, October 06, 2006 2:12 
PM To: [EMAIL PROTECTED]ups.com 
Subject: [flexcoders] Re: Format a datatip.
Ok, I have the revenue part working and formatting it. Thank you. But, I 
cannot get the MONTH to show. Month is my categoryField.  
categoryField="month:"  Below is what I have for my 
formatDataTip, but I cannot seem to find the MONTH. I have tried useing 
hitData.element and hitData.item. I thought it would be 
LineSeriesItem(hitData.chartItem).xValue, but that just gives 
me 0, 1, 2, n (guessing it is the position of data in the 
ArrayCollection I am using to populate my graph.  Any 
suggestions?  private function 
formatDataTip(hitData:HitData):String{ //var months:String = 
LineSeries(hitData.element);//Not working var name:String = 
LineSeries(hitData.element).yField; var revenue:Object = 
LineSeriesItem(hitData.chartItem).yValue; return 
"b"+name+"/bbr"+months+"br"+cf.format(revenue); 
}  --- In [EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com , "Ely Greenfield" 
egreenfi@ wrote:   
Sorry...try:
LineSeriesItem(hitData.chartItem).y.value;
Ely.  
From: 
[EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com [mailto:[EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com ] On  
Behalf Of jnewport  Sent: Tuesday, October 03, 2006 12:47 PM 
 To: [EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com   Subject: 
[flexcoders] Re: Format a datatip.  
  This throws an error."Cannot convert 
Object@ to mx.chart.series.items.LineSeriesItem"   
 /Start of 
datatipcode///  private 
function formatDataTip(hitData:HitData):String{   
 var months:String = LineSeriesItem(hitData.item).yValue; 
 var name:String = hitData.item.toString();  var 
revenue:Number = hitData.item.revenue;  return 
"b"+name+"/bbr"+months+"br"+cf.format(revenue); 
 }//End datatip 
codeAny suggestions? 
   --- In [EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com 
mailto:flexcoders%40yahoogroups.com  , "Ely 
Greenfield" egreenfi@ wrote: 
 
LineSeriesItem(hitData.item).yValue 
 Ely. 
 
 From: [EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com 
mailto:flexcoders%40yahoogroups.com  [mailto:[EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com 
mailto:flexcoders%40yahoogroups.com  ] On 
  Behalf Of jnewport   Sent: Friday, September 29, 2006 
12:35 PM   To: [EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com 
mailto:flexcoders%40yahoogroups.com
Subject: [flexcoders] Re: Format a datatip.  
  I tried that, but didn't work 
correctly.  
LineSeries.(hitData.element).yField. which gave me the State 
name,   but it won't give me the amount, which is what I am 
trying to get to   do format. 
 I have been trying to use chartItem, but no success. Flex can get 
me   all the data on its own with the showDataTips=true, so 
it knows how to   get the data out of my 
ArrayCollection. I just want to be able to get   at what 
Flex knows.   I need to get at what 
showDataTips is doing when set to True.   
Anyone know what it is?  --- In [EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com   
mailto:flexcoders%40yahoogroups.com  
mailto:flexcoders%40yahoogroups.com   , 
"Mehdi, Agha" Agha.Mehdi@ wrote:
   J,Try 
event.hitData.element.yField/.xField 
   Agha MehdiIDT - eBusiness Program 
Manager-Original 
Message-From: [EMAIL PROTECTED]ups.com 
mailto:fle

[flexcoders] Re: Format a datatip.

2006-10-11 Thread jnewport
 Code to use the dataTip

mx:CurrencyFormatter id=cf/

mx:Panel id=ComparePanel title=State Comparison width=75%
height=100%
mx:LineChart id=revlinechart
dataProvider={slicedMonthData.source}
 
showDataTips=true dataTipFunction=formatDataTip width=100% 
height=100%

mx:horizontalAxis
mx:CategoryAxis 
categoryField=month/
/mx:horizontalAxis
mx:verticalAxis
mx:LinearAxis 
maximum=16 minimum=0
labelFunction=currencyFormat/
/mx:verticalAxis


/mx:LineChart

/mx:Panel

//End MXML Code to use the dataTip

J

--- In flexcoders@yahoogroups.com, jnewport [EMAIL PROTECTED] wrote:

 Ok got it.  Thanks for all your help Ely!  I decided to rework my
 ArrayCollection and now can just use month for the categoryAxis
 instead of month:, which means I can just use hitData.item.month to
 get the month for the dataTip.
 
 J :)
 
 
 
 --- In flexcoders@yahoogroups.com, jnewport jason_newport@ wrote:
 
  Can you get direct access of horizontalAxis?  No matter what I try it
  does not like horizontalAxis.  Maybe giving it an id and directly
  accessing it by reference?
  
  J
  
  --- In flexcoders@yahoogroups.com, Ely Greenfield egreenfi@ wrote:
  



   Yup. If you don't specify an x value, it assumes the item's ordinal
   position in the data is its x value. The Cateogry Axis then lines
 up the
   value N to the nth category in _its_ data.

   The Axis objects all implement a function called formatForScreen().
   Pass it a value (i.e., like the value in xValue) and it will
 return what
   it considers to be an appropriate string to represent that value on
   string (in this case, the category name).  So get access to the
   horizontal axis, and call formatForScreen on it.

   Ely.

   
   
   
   From: flexcoders@yahoogroups.com
 [mailto:[EMAIL PROTECTED] On
   Behalf Of jnewport
   Sent: Friday, October 06, 2006 2:12 PM
   To: flexcoders@yahoogroups.com
   Subject: [flexcoders] Re: Format a datatip.
   
   
   
   Ok, I have the revenue part working and formatting it. Thank you.
   But, I cannot get the MONTH to show. Month is my categoryField.
   
   categoryField=month:
   
   Below is what I have for my formatDataTip, but I cannot seem to find
   the MONTH. I have tried useing hitData.element and hitData.item.
   I thought it would be LineSeriesItem(hitData.chartItem).xValue, but
   that just gives me 0, 1, 2, n (guessing it is the position
of data
   in the ArrayCollection I am using to populate my graph.
   
   Any suggestions?
   
   private function formatDataTip(hitData:HitData):String{
   //var months:String = LineSeries(hitData.element);//Not working
   var name:String = LineSeries(hitData.element).yField;
   var revenue:Object = LineSeriesItem(hitData.chartItem).yValue;
   return b+name+/bbr+months+br+cf.format(revenue);
   }
   
   --- In flexcoders@yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
   , Ely Greenfield egreenfi@ wrote:
   


Sorry...try:

LineSeriesItem(hitData.chartItem).y.value;

Ely.




From: flexcoders@yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
   [mailto:flexcoders@yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
   ] On
Behalf Of jnewport
Sent: Tuesday, October 03, 2006 12:47 PM
To: flexcoders@yahoogroups.com
 mailto:flexcoders%40yahoogroups.com 
Subject: [flexcoders] Re: Format a datatip.



This throws an error.

Cannot convert Object@ to mx.chart.series.items.LineSeriesItem

/Start of datatipcode///
private function formatDataTip(hitData:HitData):String{

var months:String = LineSeriesItem(hitData.item).yValue;
var name:String = hitData.item.toString();
var revenue:Number = hitData.item.revenue;
return b+name+/bbr+months+br+cf.format(revenue);
}

//End datatip code

Any suggestions?

--- In flexcoders@yahoogroups.com
   mailto:flexcoders%40yahoogroups.com
   mailto:flexcoders%40yahoogroups.com
, Ely Greenfield egreenfi@ wrote:

 
 
 
 LineSeriesItem(hitData.item).yValue
 
 Ely

[flexcoders] Re: Format a datatip.

2006-10-10 Thread jnewport
Can you get direct access of horizontalAxis?  No matter what I try it
does not like horizontalAxis.  Maybe giving it an id and directly
accessing it by reference?

J

--- In flexcoders@yahoogroups.com, Ely Greenfield [EMAIL PROTECTED] wrote:

  
  
  
 Yup. If you don't specify an x value, it assumes the item's ordinal
 position in the data is its x value. The Cateogry Axis then lines up the
 value N to the nth category in _its_ data.
  
 The Axis objects all implement a function called formatForScreen().
 Pass it a value (i.e., like the value in xValue) and it will return what
 it considers to be an appropriate string to represent that value on
 string (in this case, the category name).  So get access to the
 horizontal axis, and call formatForScreen on it.
  
 Ely.
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of jnewport
 Sent: Friday, October 06, 2006 2:12 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Re: Format a datatip.
 
 
 
 Ok, I have the revenue part working and formatting it. Thank you.
 But, I cannot get the MONTH to show. Month is my categoryField.
 
 categoryField=month:
 
 Below is what I have for my formatDataTip, but I cannot seem to find
 the MONTH. I have tried useing hitData.element and hitData.item.
 I thought it would be LineSeriesItem(hitData.chartItem).xValue, but
 that just gives me 0, 1, 2, n (guessing it is the position of data
 in the ArrayCollection I am using to populate my graph.
 
 Any suggestions?
 
 private function formatDataTip(hitData:HitData):String{
 //var months:String = LineSeries(hitData.element);//Not working
 var name:String = LineSeries(hitData.element).yField;
 var revenue:Object = LineSeriesItem(hitData.chartItem).yValue;
 return b+name+/bbr+months+br+cf.format(revenue);
 }
 
 --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 , Ely Greenfield egreenfi@ wrote:
 
  
  
  Sorry...try:
  
  LineSeriesItem(hitData.chartItem).y.value;
  
  Ely.
  
  
  
  
  From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 [mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 ] On
  Behalf Of jnewport
  Sent: Tuesday, October 03, 2006 12:47 PM
  To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com 
  Subject: [flexcoders] Re: Format a datatip.
  
  
  
  This throws an error.
  
  Cannot convert Object@ to mx.chart.series.items.LineSeriesItem
  
  /Start of datatipcode///
  private function formatDataTip(hitData:HitData):String{
  
  var months:String = LineSeriesItem(hitData.item).yValue;
  var name:String = hitData.item.toString();
  var revenue:Number = hitData.item.revenue;
  return b+name+/bbr+months+br+cf.format(revenue);
  }
  
  //End datatip code
  
  Any suggestions?
  
  --- In flexcoders@yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
  , Ely Greenfield egreenfi@ wrote:
  
   
   
   
   LineSeriesItem(hitData.item).yValue
   
   Ely.
   
   
   
   
   From: flexcoders@yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
  [mailto:flexcoders@yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
  ] On
   Behalf Of jnewport
   Sent: Friday, September 29, 2006 12:35 PM
   To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 mailto:flexcoders%40yahoogroups.com 
   Subject: [flexcoders] Re: Format a datatip.
   
   
   
   I tried that, but didn't work correctly.
   
   LineSeries.(hitData.element).yField. which gave me the State name,
   but it won't give me the amount, which is what I am trying to get to
   do format.
   
   I have been trying to use chartItem, but no success. Flex can get me
   all the data on its own with the showDataTips=true, so it knows how
 to
   get the data out of my ArrayCollection. I just want to be able to
 get
   at what Flex knows. 
   
   I need to get at what showDataTips is doing when set to True. 
   
   Anyone know what it is?
   
   --- In flexcoders@yahoogroups.com
 mailto:flexcoders%40yahoogroups.com 
  mailto:flexcoders%40yahoogroups.com
  mailto:flexcoders%40yahoogroups.com
   , Mehdi, Agha Agha.Mehdi@ wrote:
   
J,

Try event.hitData.element.yField/.xField

Agha Mehdi
IDT - eBusiness Program Manager

-Original Message-
From: flexcoders@yahoogroups.com
 mailto:flexcoders%40yahoogroups.com 
  mailto:flexcoders%40yahoogroups.com
  mailto:flexcoders%40yahoogroups.com
   [mailto:flexcoders@yahoogroups.com
 mailto:flexcoders%40yahoogroups.com 
  mailto:flexcoders%40yahoogroups.com
  mailto:flexcoders%40yahoogroups.com
   ] On
Behalf Of jnewport
Sent: Friday, September 29, 2006 9:11 AM
To: flexcoders@yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
 mailto:flexcoders

[flexcoders] Re: Format a datatip.

2006-10-10 Thread jnewport
Ok got it.  Thanks for all your help Ely!  I decided to rework my
ArrayCollection and now can just use month for the categoryAxis
instead of month:, which means I can just use hitData.item.month to
get the month for the dataTip.

J :)



--- In flexcoders@yahoogroups.com, jnewport [EMAIL PROTECTED] wrote:

 Can you get direct access of horizontalAxis?  No matter what I try it
 does not like horizontalAxis.  Maybe giving it an id and directly
 accessing it by reference?
 
 J
 
 --- In flexcoders@yahoogroups.com, Ely Greenfield egreenfi@ wrote:
 
   
   
   
  Yup. If you don't specify an x value, it assumes the item's ordinal
  position in the data is its x value. The Cateogry Axis then lines
up the
  value N to the nth category in _its_ data.
   
  The Axis objects all implement a function called formatForScreen().
  Pass it a value (i.e., like the value in xValue) and it will
return what
  it considers to be an appropriate string to represent that value on
  string (in this case, the category name).  So get access to the
  horizontal axis, and call formatForScreen on it.
   
  Ely.
   
  
  
  
  From: flexcoders@yahoogroups.com
[mailto:[EMAIL PROTECTED] On
  Behalf Of jnewport
  Sent: Friday, October 06, 2006 2:12 PM
  To: flexcoders@yahoogroups.com
  Subject: [flexcoders] Re: Format a datatip.
  
  
  
  Ok, I have the revenue part working and formatting it. Thank you.
  But, I cannot get the MONTH to show. Month is my categoryField.
  
  categoryField=month:
  
  Below is what I have for my formatDataTip, but I cannot seem to find
  the MONTH. I have tried useing hitData.element and hitData.item.
  I thought it would be LineSeriesItem(hitData.chartItem).xValue, but
  that just gives me 0, 1, 2, n (guessing it is the position of data
  in the ArrayCollection I am using to populate my graph.
  
  Any suggestions?
  
  private function formatDataTip(hitData:HitData):String{
  //var months:String = LineSeries(hitData.element);//Not working
  var name:String = LineSeries(hitData.element).yField;
  var revenue:Object = LineSeriesItem(hitData.chartItem).yValue;
  return b+name+/bbr+months+br+cf.format(revenue);
  }
  
  --- In flexcoders@yahoogroups.com
mailto:flexcoders%40yahoogroups.com
  , Ely Greenfield egreenfi@ wrote:
  
   
   
   Sorry...try:
   
   LineSeriesItem(hitData.chartItem).y.value;
   
   Ely.
   
   
   
   
   From: flexcoders@yahoogroups.com
mailto:flexcoders%40yahoogroups.com
  [mailto:flexcoders@yahoogroups.com
mailto:flexcoders%40yahoogroups.com
  ] On
   Behalf Of jnewport
   Sent: Tuesday, October 03, 2006 12:47 PM
   To: flexcoders@yahoogroups.com
mailto:flexcoders%40yahoogroups.com 
   Subject: [flexcoders] Re: Format a datatip.
   
   
   
   This throws an error.
   
   Cannot convert Object@ to mx.chart.series.items.LineSeriesItem
   
   /Start of datatipcode///
   private function formatDataTip(hitData:HitData):String{
   
   var months:String = LineSeriesItem(hitData.item).yValue;
   var name:String = hitData.item.toString();
   var revenue:Number = hitData.item.revenue;
   return b+name+/bbr+months+br+cf.format(revenue);
   }
   
   //End datatip code
   
   Any suggestions?
   
   --- In flexcoders@yahoogroups.com
  mailto:flexcoders%40yahoogroups.com
  mailto:flexcoders%40yahoogroups.com
   , Ely Greenfield egreenfi@ wrote:
   



LineSeriesItem(hitData.item).yValue

Ely.




From: flexcoders@yahoogroups.com
  mailto:flexcoders%40yahoogroups.com
  mailto:flexcoders%40yahoogroups.com
   [mailto:flexcoders@yahoogroups.com
  mailto:flexcoders%40yahoogroups.com
  mailto:flexcoders%40yahoogroups.com
   ] On
Behalf Of jnewport
Sent: Friday, September 29, 2006 12:35 PM
To: flexcoders@yahoogroups.com
mailto:flexcoders%40yahoogroups.com
  mailto:flexcoders%40yahoogroups.com 
Subject: [flexcoders] Re: Format a datatip.



I tried that, but didn't work correctly.

LineSeries.(hitData.element).yField. which gave me the State name,
but it won't give me the amount, which is what I am trying to
get to
do format.

I have been trying to use chartItem, but no success. Flex can
get me
all the data on its own with the showDataTips=true, so it
knows how
  to
get the data out of my ArrayCollection. I just want to be able to
  get
at what Flex knows. 

I need to get at what showDataTips is doing when set to True. 

Anyone know what it is?

--- In flexcoders@yahoogroups.com
  mailto:flexcoders%40yahoogroups.com 
   mailto:flexcoders%40yahoogroups.com
   mailto:flexcoders%40yahoogroups.com
, Mehdi, Agha Agha.Mehdi@ wrote:

 J,
 
 Try event.hitData.element.yField/.xField
 
 Agha Mehdi
 IDT - eBusiness Program Manager
 
 -Original Message-
 From

[flexcoders] Re: Format a datatip.

2006-10-10 Thread davidmartinomalley
J, can you post the finalized code - for those of us trying to follow 
along?

Cheers,

David






--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

* To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

* Your email settings:
Individual Email | Traditional

* To change settings online go to:
http://groups.yahoo.com/group/flexcoders/join
(Yahoo! ID required)

* To change settings via email:
mailto:[EMAIL PROTECTED] 
mailto:[EMAIL PROTECTED]

* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
 




RE: [flexcoders] Re: Format a datatip.

2006-10-09 Thread Ely Greenfield








Yup. If you don't specify an x value, it assumes the item's 
ordinal position in the data is its x value. The Cateogry Axis then lines up the 
value N to the nth category in _its_ data.

The Axis objects all implement a function called 
formatForScreen(). Pass it a value (i.e., like the value in xValue) and it 
will return what it considers to be an appropriate string to represent that 
value on string (in this case, the category name). So get access to the 
horizontal axis, and call formatForScreen on it.

Ely.



From: flexcoders@yahoogroups.com 
[mailto:[EMAIL PROTECTED] On Behalf Of jnewportSent: 
Friday, October 06, 2006 2:12 PMTo: 
flexcoders@yahoogroups.comSubject: [flexcoders] Re: Format a 
datatip.


Ok, I have the revenue part working and formatting it. Thank you.But, I 
cannot get the MONTH to show. Month is my 
categoryField.categoryField="month:"Below is what I have 
for my formatDataTip, but I cannot seem to findthe MONTH. I have tried 
useing hitData.element and hitData.item.I thought it would be 
LineSeriesItem(hitData.chartItem).xValue, butthat just gives me 0, 
1, 2, n (guessing it is the position of datain the ArrayCollection I am 
using to populate my graph.Any suggestions?private function 
formatDataTip(hitData:HitData):String{//var months:String = 
LineSeries(hitData.element);//Not workingvar name:String = 
LineSeries(hitData.element).yField;var revenue:Object = 
LineSeriesItem(hitData.chartItem).yValue;return 
"b"+name+"/bbr"+months+"br"+cf.format(revenue);}--- 
In [EMAIL PROTECTED]ups.com, 
"Ely Greenfield" [EMAIL PROTECTED]. wrote:  
 Sorry...try:  
LineSeriesItem(hitData.chartItem).y.value;  
Ely.   
  From: [EMAIL PROTECTED]ups.com 
[mailto:[EMAIL PROTECTED]ups.com] 
On Behalf Of jnewport Sent: Tuesday, October 03, 2006 12:47 
PM To: [EMAIL PROTECTED]ups.com 
Subject: [flexcoders] Re: Format a datatip.
This throws an error.  "Cannot convert Object@ to 
mx.chart.series.items.LineSeriesItem"  /Start 
of datatipcode/// private 
function formatDataTip(hitData:HitData):String{  var 
months:String = LineSeriesItem(hitData.item).yValue; var 
name:String = hitData.item.toString(); var revenue:Number = 
hitData.item.revenue; return 
"b"+name+"/bbr"+months+"br"+cf.format(revenue); 
}  //End datatip 
code  Any suggestions?  --- 
In [EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com , "Ely Greenfield" 
egreenfi@ wrote:   
  LineSeriesItem(hitData.item).yValue  
  Ely.  
From: 
[EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com [mailto:[EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com ] On  
Behalf Of jnewport  Sent: Friday, September 29, 2006 12:35 
PM  To: [EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com   Subject: 
[flexcoders] Re: Format a datatip.  
  I tried that, but didn't work correctly.   
 LineSeries.(hitData.element).yField. which gave me the State 
name,  but it won't give me the amount, which is what I am trying to 
get to  do format.I have been trying to 
use chartItem, but no success. Flex can get me  all the data on its 
own with the showDataTips=true, so it knows how to  get the 
data out of my ArrayCollection. I just want to be able to get  at 
what Flex knows. I need to get at what showDataTips 
is doing when set to True. Anyone know what it 
is?--- In [EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com 
mailto:flexcoders%40yahoogroups.com  , "Mehdi, 
Agha" Agha.Mehdi@ wrote: 
J,  Try 
event.hitData.element.yField/.xField 
 Agha Mehdi   IDT - eBusiness Program Manager  
-Original Message-   From: [EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com 
mailto:flexcoders%40yahoogroups.com  [mailto:[EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com 
mailto:flexcoders%40yahoogroups.com  ] On 
  Behalf Of jnewport   Sent: Friday, September 29, 2006 
9:11 AM   To: [EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com 
mailto:flexcoders%40yahoogroups.com
Subject: [flexcoders] Format a datatip.  I 
was wondering how to format a datatip for a LineChart. If I use  
 showDataTips everything looks good but the amounts are not 
formatted   to $##,###. I have created an ArrayCollection that 
looks like the   following.  
private var expensesAC:ArrayCollection = new ArrayCollection( [ 
  { Month: "Jan", Texas: 2000, Utah: 1500, Kansas: 450 },  
 { Month: "Feb", Texas: 1000, Utah: 200, Kansas: 600 },   { 
Month: "Mar", Texas: 1500, Utah: 500, Kansas: 300 },   { Month: 
"Apr", Texas: 1800, Utah: 1200, Kansas: 900 },   { Month: "May", 
Texas: 2400, Utah: 575, Kansas: 500 } ]);  I 
have tried to use cf.format(); on the data before its p

[flexcoders] Re: Format a datatip.

2006-10-06 Thread jnewport
Ok, I have the revenue part working and formatting it.  Thank you.
But, I cannot get the MONTH to show.  Month is my categoryField.

 categoryField=month:

Below is what I have for my formatDataTip, but I cannot seem to find
the MONTH.  I have tried useing hitData.element and hitData.item.
I thought it would be LineSeriesItem(hitData.chartItem).xValue, but
that just gives me 0, 1, 2, n (guessing it is the position of data
in the ArrayCollection I am using to populate my graph.

Any suggestions?

private function formatDataTip(hitData:HitData):String{
   //var months:String = LineSeries(hitData.element);//Not working
   var name:String = LineSeries(hitData.element).yField;
   var revenue:Object = LineSeriesItem(hitData.chartItem).yValue;
   return b+name+/bbr+months+br+cf.format(revenue);
}






--- In flexcoders@yahoogroups.com, Ely Greenfield [EMAIL PROTECTED] wrote:

  
  
 Sorry...try:
  
 LineSeriesItem(hitData.chartItem).y.value;
  
 Ely.
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of jnewport
 Sent: Tuesday, October 03, 2006 12:47 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Re: Format a datatip.
 
 
 
 This throws an error.
 
 Cannot convert Object@ to mx.chart.series.items.LineSeriesItem
 
 /Start of datatipcode///
 private function formatDataTip(hitData:HitData):String{
 
 var months:String = LineSeriesItem(hitData.item).yValue;
 var name:String = hitData.item.toString();
 var revenue:Number = hitData.item.revenue;
 return b+name+/bbr+months+br+cf.format(revenue);
 }
 
 //End datatip code
 
 Any suggestions?
 
 --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 , Ely Greenfield egreenfi@ wrote:
 
  
  
  
  LineSeriesItem(hitData.item).yValue
  
  Ely.
  
  
  
  
  From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 [mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 ] On
  Behalf Of jnewport
  Sent: Friday, September 29, 2006 12:35 PM
  To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com 
  Subject: [flexcoders] Re: Format a datatip.
  
  
  
  I tried that, but didn't work correctly.
  
  LineSeries.(hitData.element).yField. which gave me the State name,
  but it won't give me the amount, which is what I am trying to get to
  do format.
  
  I have been trying to use chartItem, but no success. Flex can get me
  all the data on its own with the showDataTips=true, so it knows how to
  get the data out of my ArrayCollection. I just want to be able to get
  at what Flex knows. 
  
  I need to get at what showDataTips is doing when set to True. 
  
  Anyone know what it is?
  
  --- In flexcoders@yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
  , Mehdi, Agha Agha.Mehdi@ wrote:
  
   J,
   
   Try event.hitData.element.yField/.xField
   
   Agha Mehdi
   IDT - eBusiness Program Manager
   
   -Original Message-
   From: flexcoders@yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
  [mailto:flexcoders@yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
  ] On
   Behalf Of jnewport
   Sent: Friday, September 29, 2006 9:11 AM
   To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 mailto:flexcoders%40yahoogroups.com 
   Subject: [flexcoders] Format a datatip.
   
   I was wondering how to format a datatip for a LineChart. If I use
   showDataTips everything looks good but the amounts are not formatted
   to $##,###. I have created an ArrayCollection that looks like the
   following.
   
   private var expensesAC:ArrayCollection = new ArrayCollection( [
   { Month: Jan, Texas: 2000, Utah: 1500, Kansas: 450 },
   { Month: Feb, Texas: 1000, Utah: 200, Kansas: 600 },
   { Month: Mar, Texas: 1500, Utah: 500, Kansas: 300 },
   { Month: Apr, Texas: 1800, Utah: 1200, Kansas: 900 },
   { Month: May, Texas: 2400, Utah: 575, Kansas: 500 } ]);
   
   I have tried to use cf.format(); on the data before its put into the
   ArrayCollection, which works so I get something like this.
   
   private var expensesAC:ArrayCollection = new ArrayCollection( [
   { Month: Jan, Texas: $2,000, Utah: $1,500, Kansas: $450 },
   
   But then Flex won't plot the dataguessing it doesn't like the
 $.
  
   
   
   So I am trying to use a function like this
   
   private function formatDataTip(hitData:HitData):String {
   var month:String = hitData.item.DONTKNOWWHATSHOULDGOHERE
   
   but I don't know what should come after item. I have tried to do a
   trace(hitData.item.toString), but I get object object. Is there a
 way
   to trace out whats in the hitData.item? 
   
   J
   
   
   
   
   
   
   --
   Flexcoders Mailing List
   FAQ:
 http://groups.yahoo.com/group/flexcoders/files

RE: [flexcoders] Re: Format a datatip.

2006-10-05 Thread Ely Greenfield







Sorry...try:

LineSeriesItem(hitData.chartItem).y.value;

Ely.



From: flexcoders@yahoogroups.com 
[mailto:[EMAIL PROTECTED] On Behalf Of jnewportSent: 
Tuesday, October 03, 2006 12:47 PMTo: 
flexcoders@yahoogroups.comSubject: [flexcoders] Re: Format a 
datatip.


This throws an error."Cannot convert [EMAIL PROTECTED] to 
mx.chart.series.items.LineSeriesItem"/Start of 
datatipcode///private function 
formatDataTip(hitData:HitData):String{var months:String = 
LineSeriesItem(hitData.item).yValue;var name:String = 
hitData.item.toString();var revenue:Number = 
hitData.item.revenue;return 
"b"+name+"/bbr"+months+"br"+cf.format(revenue);}//End 
datatip codeAny suggestions?--- In [EMAIL PROTECTED]ups.com, 
"Ely Greenfield" [EMAIL PROTECTED]. wrote:  
  LineSeriesItem(hitData.item).yValue  
Ely.   
  From: [EMAIL PROTECTED]ups.com 
[mailto:[EMAIL PROTECTED]ups.com] 
On Behalf Of jnewport Sent: Friday, September 29, 2006 12:35 
PM To: [EMAIL PROTECTED]ups.com 
Subject: [flexcoders] Re: Format a datatip.I 
tried that, but didn't work correctly.  
LineSeries.(hitData.element).yField. which gave me the State 
name, but it won't give me the amount, which is what I am trying to get 
to do format.  I have been trying to use chartItem, but 
no success. Flex can get me all the data on its own with the 
showDataTips=true, so it knows how to get the data out of my 
ArrayCollection. I just want to be able to get at what Flex knows. 
  I need to get at what showDataTips is doing when set to True. 
  Anyone know what it is?  --- In [EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com , "Mehdi, Agha" 
Agha.Mehdi@ wrote:   J,  
  Try event.hitData.element.yField/.xField  
  Agha Mehdi  IDT - eBusiness Program Manager 
   -Original Message-  From: [EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com [mailto:[EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com ] On  
Behalf Of jnewport  Sent: Friday, September 29, 2006 9:11 AM 
 To: [EMAIL PROTECTED]ups.com 
mailto:flexcoders%40yahoogroups.com   Subject: 
[flexcoders] Format a datatip.I was wondering how to 
format a datatip for a LineChart. If I use  showDataTips everything 
looks good but the amounts are not formatted  to $##,###. I have 
created an ArrayCollection that looks like the  following. 
   private var expensesAC:ArrayCollection = new 
ArrayCollection( [  { Month: "Jan", Texas: 2000, Utah: 1500, Kansas: 
450 },  { Month: "Feb", Texas: 1000, Utah: 200, Kansas: 600 
},  { Month: "Mar", Texas: 1500, Utah: 500, Kansas: 300 }, 
 { Month: "Apr", Texas: 1800, Utah: 1200, Kansas: 900 },  { 
Month: "May", Texas: 2400, Utah: 575, Kansas: 500 } ]);   
 I have tried to use cf.format(); on the data before its put into 
the  ArrayCollection, which works so I get something like 
this.private var expensesAC:ArrayCollection = 
new ArrayCollection( [  { Month: "Jan", Texas: $2,000, Utah: $1,500, 
Kansas: $450 },But then Flex won't plot the 
dataguessing it doesn't like the "$". 
  So I am trying to use a function like this   
 private function formatDataTip(hitData:HitData):String { 
 var month:String = hitData.item.DONTKNOWWHATSHOULDGOHERE 
   but I don't know what should come after item. I have tried to 
do a  trace(hitData.item.toString), but I get object 
object. Is there a way  to trace out whats in the hitData.item? 
J   
   --  Flexcoders 
Mailing List  FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt 
http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt 
  Search Archives:  http://www.mail-archive.com/flexcoders%40yahoogroups.com 
http://www.mail-archive.com/flexcoders%40yahoogroups.com 
  Yahoo! Groups Links 
__._,_.___





--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com








   






  
  
SPONSORED LINKS
  
  
  

Software development tool
  
  
Software development
  
  
Software development services
  
  


Home design software
  
  
Software development company
  

   
  






  
  Your email settings: Individual Email|Traditional 
  Change settings via the Web (Yahoo! ID required) 
  Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured 
   
Visit Your Group 
   |
  
Yahoo! Groups Terms of Use
   |
  
   Unsubscribe 
   
 

  




__,_._,___



[flexcoders] Re: Format a datatip.

2006-10-03 Thread jnewport
This throws an error.

Cannot convert [EMAIL PROTECTED] to mx.chart.series.items.LineSeriesItem

/Start of datatipcode///
private function formatDataTip(hitData:HitData):String{

   var months:String = LineSeriesItem(hitData.item).yValue;
   var name:String = hitData.item.toString();
   var revenue:Number = hitData.item.revenue;
   return b+name+/bbr+months+br+cf.format(revenue);
}

//End datatip code

Any suggestions?

--- In flexcoders@yahoogroups.com, Ely Greenfield [EMAIL PROTECTED] wrote:

  
  
  
 LineSeriesItem(hitData.item).yValue
  
 Ely.
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of jnewport
 Sent: Friday, September 29, 2006 12:35 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Re: Format a datatip.
 
 
 
 I tried that, but didn't work correctly.
 
 LineSeries.(hitData.element).yField. which gave me the State name,
 but it won't give me the amount, which is what I am trying to get to
 do format.
 
 I have been trying to use chartItem, but no success. Flex can get me
 all the data on its own with the showDataTips=true, so it knows how to
 get the data out of my ArrayCollection. I just want to be able to get
 at what Flex knows. 
 
 I need to get at what showDataTips is doing when set to True. 
 
 Anyone know what it is?
 
 --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 , Mehdi, Agha Agha.Mehdi@ wrote:
 
  J,
  
  Try event.hitData.element.yField/.xField
  
  Agha Mehdi
  IDT - eBusiness Program Manager
  
  -Original Message-
  From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 [mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 ] On
  Behalf Of jnewport
  Sent: Friday, September 29, 2006 9:11 AM
  To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com 
  Subject: [flexcoders] Format a datatip.
  
  I was wondering how to format a datatip for a LineChart. If I use
  showDataTips everything looks good but the amounts are not formatted
  to $##,###. I have created an ArrayCollection that looks like the
  following.
  
  private var expensesAC:ArrayCollection = new ArrayCollection( [
  { Month: Jan, Texas: 2000, Utah: 1500, Kansas: 450 },
  { Month: Feb, Texas: 1000, Utah: 200, Kansas: 600 },
  { Month: Mar, Texas: 1500, Utah: 500, Kansas: 300 },
  { Month: Apr, Texas: 1800, Utah: 1200, Kansas: 900 },
  { Month: May, Texas: 2400, Utah: 575, Kansas: 500 } ]);
  
  I have tried to use cf.format(); on the data before its put into the
  ArrayCollection, which works so I get something like this.
  
  private var expensesAC:ArrayCollection = new ArrayCollection( [
  { Month: Jan, Texas: $2,000, Utah: $1,500, Kansas: $450 },
  
  But then Flex won't plot the dataguessing it doesn't like the $.
 
  
  
  So I am trying to use a function like this
  
  private function formatDataTip(hitData:HitData):String {
  var month:String = hitData.item.DONTKNOWWHATSHOULDGOHERE
  
  but I don't know what should come after item. I have tried to do a
  trace(hitData.item.toString), but I get object object. Is there a way
  to trace out whats in the hitData.item? 
  
  J
  
  
  
  
  
  
  --
  Flexcoders Mailing List
  FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
 http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt 
  Search Archives:
  http://www.mail-archive.com/flexcoders%40yahoogroups.com
 http://www.mail-archive.com/flexcoders%40yahoogroups.com  
  Yahoo! Groups Links
 








--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

* To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

* Your email settings:
Individual Email | Traditional

* To change settings online go to:
http://groups.yahoo.com/group/flexcoders/join
(Yahoo! ID required)

* To change settings via email:
mailto:[EMAIL PROTECTED] 
mailto:[EMAIL PROTECTED]

* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
 





Re: [flexcoders] Re: Format a datatip.

2006-10-03 Thread Igor Costa



here a example friendprivate function toolTipReport(e:HitData):String{ var relatorioTip:String = ;  relatorioTip += bQuestionamento:/b +e.item.col_1+br;
  relatorioTip += bTotal da rede:/b + e.item.col_2 + br;  relatorioTip +=bValor:/b  + e.item.col_3+br;
  relatorioTip +=bSegmento:/b +e.item.col_5+ br;  relatorioTip += bMês base:/b  + e.item.col_6+ br;
  relatorioTip += bPeríodo:/b  + e.item.col_7;  return relatorioTip;  }Regards.just put an property to your Columnseries like dataTipFunction=nameOfFunctionHere and will works.
On 10/3/06, jnewport [EMAIL PROTECTED] wrote:













  



This throws an error.

Cannot convert [EMAIL PROTECTED] to mx.chart.series.items.LineSeriesItem

/Start of datatipcode///
private function formatDataTip(hitData:HitData):String{
	
   var months:String = LineSeriesItem(hitData.item).yValue;
   var name:String = hitData.item.toString();
   var revenue:Number = hitData.item.revenue;
   return b+name+/bbr+months+br+cf.format(revenue);
}

//End datatip code

Any suggestions?

--- In flexcoders@yahoogroups.com, Ely Greenfield [EMAIL PROTECTED] wrote:

  
  
  
 LineSeriesItem(hitData.item).yValue
  
 Ely.
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:
flexcoders@yahoogroups.com] On
 Behalf Of jnewport
 Sent: Friday, September 29, 2006 12:35 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Re: Format a datatip.
 
 
 
 I tried that, but didn't work correctly.
 
 LineSeries.(hitData.element).yField. which gave me the State name,
 but it won't give me the amount, which is what I am trying to get to
 do format.
 
 I have been trying to use chartItem, but no success. Flex can get me
 all the data on its own with the showDataTips=true, so it knows how to
 get the data out of my ArrayCollection. I just want to be able to get
 at what Flex knows. 
 
 I need to get at what showDataTips is doing when set to True. 
 
 Anyone know what it is?
 
 --- In flexcoders@yahoogroups.com mailto:
flexcoders%40yahoogroups.com
 , Mehdi, Agha Agha.Mehdi@ wrote:
 
  J,
  
  Try event.hitData.element.yField/.xField
  
  Agha Mehdi
  IDT - eBusiness Program Manager
  
  -Original Message-
  From: flexcoders@yahoogroups.com mailto:
flexcoders%40yahoogroups.com
 [mailto:flexcoders@yahoogroups.com mailto:
flexcoders%40yahoogroups.com
 ] On
  Behalf Of jnewport
  Sent: Friday, September 29, 2006 9:11 AM
  To: flexcoders@yahoogroups.com mailto:
flexcoders%40yahoogroups.com 
  Subject: [flexcoders] Format a datatip.
  
  I was wondering how to format a datatip for a LineChart. If I use
  showDataTips everything looks good but the amounts are not formatted
  to $##,###. I have created an ArrayCollection that looks like the
  following.
  
  private var expensesAC:ArrayCollection = new ArrayCollection( [
  { Month: Jan, Texas: 2000, Utah: 1500, Kansas: 450 },
  { Month: Feb, Texas: 1000, Utah: 200, Kansas: 600 },
  { Month: Mar, Texas: 1500, Utah: 500, Kansas: 300 },
  { Month: Apr, Texas: 1800, Utah: 1200, Kansas: 900 },
  { Month: May, Texas: 2400, Utah: 575, Kansas: 500 } ]);
  
  I have tried to use cf.format(); on the data before its put into the
  ArrayCollection, which works so I get something like this.
  
  private var expensesAC:ArrayCollection = new ArrayCollection( [
  { Month: Jan, Texas: $2,000, Utah: $1,500, Kansas: $450 },
  
  But then Flex won't plot the dataguessing it doesn't like the $.
 
  
  
  So I am trying to use a function like this
  
  private function formatDataTip(hitData:HitData):String {
  var month:String = hitData.item.DONTKNOWWHATSHOULDGOHERE
  
  but I don't know what should come after item. I have tried to do a
  trace(hitData.item.toString), but I get object object. Is there a way
  to trace out whats in the hitData.item? 
  
  J
  
  
  
  
  
  
  --
  Flexcoders Mailing List
  FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt

 http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
 
  Search Archives:
  http://www.mail-archive.com/flexcoders%40yahoogroups.com
 http://www.mail-archive.com/flexcoders%40yahoogroups.com  
  Yahoo! Groups Links
 



  













-- Igor Costawww.igorcosta.com

__._,_.___





--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com








   






  
  
SPONSORED LINKS
  
  
  

Software development tool
  
  
Software development
  
  
Software development services
  
  


Home design software
  
  
Software development company

RE: [flexcoders] Re: Format a datatip.

2006-10-01 Thread Ely Greenfield








LineSeriesItem(hitData.item).yValue

Ely.



From: flexcoders@yahoogroups.com 
[mailto:[EMAIL PROTECTED] On Behalf Of jnewportSent: 
Friday, September 29, 2006 12:35 PMTo: 
flexcoders@yahoogroups.comSubject: [flexcoders] Re: Format a 
datatip.


I tried that, but didn't work 
correctly.LineSeries.(hitData.element).yField. which gave me 
the State name,but it won't give me the amount, which is what I am trying to 
get todo format.I have been trying to use chartItem, but no success. 
Flex can get meall the data on its own with the showDataTips=true, so 
it knows how toget the data out of my ArrayCollection. I just want to be 
able to getat what Flex knows. I need to get at what showDataTips is 
doing when set to True. Anyone know what it is?--- In [EMAIL PROTECTED]ups.com, 
"Mehdi, Agha" Agha.Mehdi@... wrote: J, 
 Try event.hitData.element.yField/.xField  
Agha Mehdi IDT - eBusiness Program Manager  
-Original Message- From: [EMAIL PROTECTED]ups.com 
[mailto:[EMAIL PROTECTED]ups.com] 
On Behalf Of jnewport Sent: Friday, September 29, 2006 9:11 
AM To: [EMAIL PROTECTED]ups.com 
Subject: [flexcoders] Format a datatip.  I was wondering how to 
format a datatip for a LineChart. If I use showDataTips everything looks 
good but the amounts are not formatted to $##,###. I have created an 
ArrayCollection that looks like the following.  private 
var expensesAC:ArrayCollection = new ArrayCollection( [ { Month: 
"Jan", Texas: 2000, Utah: 1500, Kansas: 450 }, { Month: "Feb", Texas: 
1000, Utah: 200, Kansas: 600 }, { Month: "Mar", Texas: 1500, Utah: 500, 
Kansas: 300 }, { Month: "Apr", Texas: 1800, Utah: 1200, Kansas: 900 
}, { Month: "May", Texas: 2400, Utah: 575, Kansas: 500 } ]); 
 I have tried to use cf.format(); on the data before its put into 
the ArrayCollection, which works so I get something like this. 
 private var expensesAC:ArrayCollection = new ArrayCollection( 
[ { Month: "Jan", Texas: $2,000, Utah: $1,500, Kansas: $450 }, 
 But then Flex won't plot the dataguessing it doesn't like the "$". 
   So I am trying to use a function like this 
 private function formatDataTip(hitData:HitData):String 
{ var month:String = 
hitData.item.DONTKNOWWHATSHOULDGOHERE  but I don't 
know what should come after item. I have tried to do a 
trace(hitData.item.toString), but I get object object. Is there a 
way to trace out whats in the hitData.item?   J 
  -- Flexcoders 
Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt 
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
 Yahoo! Groups Links
__._,_.___





--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com








   






  
  
SPONSORED LINKS
  
  
  

Software development tool
  
  
Software development
  
  
Software development services
  
  


Home design software
  
  
Software development company
  

   
  






  
  Your email settings: Individual Email|Traditional 
  Change settings via the Web (Yahoo! ID required) 
  Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured 
   
Visit Your Group 
   |
  
Yahoo! Groups Terms of Use
   |
  
   Unsubscribe 
   
 

  




__,_._,___



[flexcoders] Re: Format a datatip.

2006-09-29 Thread jnewport
I tried that, but didn't work correctly.

LineSeries.(hitData.element).yField.  which gave me the State name,
but it won't give me the amount, which is what I am trying to get to
do format.

I have been trying to use chartItem, but no success.  Flex can get me
all the data on its own with the showDataTips=true, so it knows how to
get the data out of my ArrayCollection.  I just want to be able to get
at what Flex knows.  

I need to get at what showDataTips is doing when set to True.  

Anyone know what it is?




--- In flexcoders@yahoogroups.com, Mehdi, Agha [EMAIL PROTECTED] wrote:

 J,
 
 Try event.hitData.element.yField/.xField
 
 Agha Mehdi
 IDT - eBusiness Program Manager
 
 -Original Message-
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of jnewport
 Sent: Friday, September 29, 2006 9:11 AM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Format a datatip.
 
 I was wondering how to format a datatip for a LineChart. If I use
 showDataTips everything looks good but the amounts are not formatted
 to $##,###.  I have created an ArrayCollection that looks like the
 following.
 
 private var expensesAC:ArrayCollection = new ArrayCollection( [
 { Month: Jan, Texas: 2000, Utah: 1500, Kansas: 450 },
 { Month: Feb, Texas: 1000, Utah: 200, Kansas: 600 },
 { Month: Mar, Texas: 1500, Utah: 500, Kansas: 300 },
 { Month: Apr, Texas: 1800, Utah: 1200, Kansas: 900 },
 { Month: May, Texas: 2400, Utah: 575, Kansas: 500 } ]);
 
 I have tried to use cf.format(); on the data before its put into the
 ArrayCollection, which works so I get something like this.
 
 private var expensesAC:ArrayCollection = new ArrayCollection( [
 { Month: Jan, Texas: $2,000, Utah: $1,500, Kansas: $450 },
 
 But then Flex won't plot the dataguessing it doesn't like the $.  
 
 
 So I am trying to use a function like this
 
 private function formatDataTip(hitData:HitData):String {
 var month:String = hitData.item.DONTKNOWWHATSHOULDGOHERE
 
 but I don't know what should come after item. I have tried to do a
 trace(hitData.item.toString), but I get object object.  Is there a way
 to trace out whats in the hitData.item? 
 
 J
 
 
 
 
 
 
 --
 Flexcoders Mailing List
 FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
 Search Archives:
 http://www.mail-archive.com/flexcoders%40yahoogroups.com 
 Yahoo! Groups Links







--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

* To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

* Your email settings:
Individual Email | Traditional

* To change settings online go to:
http://groups.yahoo.com/group/flexcoders/join
(Yahoo! ID required)

* To change settings via email:
mailto:[EMAIL PROTECTED] 
mailto:[EMAIL PROTECTED]

* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/