This is because you’re modifying the
mystring value yourself, you shouldn’t be doing += which I believe acts
like append in AS2, instead you should simply return mystring + “%”
Hello,
if I use a labeling function for the horizontal
axis within the
BarChart component, it labels in a strange way.
The axis is defined like this:
<mx:horizontalAxisRenderer><mx:AxisRenderer
canDropLabels="true"
tickLength="1"
tickPlacement="inside" labelGap="0"
labelFunction="strPercent">....
I found out only checking if label isn't already
modified in the
labeling function brings the needed result (1 time
%):
function strPercent(mystring) {
if
(mystring.lastIndexOf("%")==-1) mystring += "%";
return mystring;
}
Any ideas why it labels multiple times?
--
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
YAHOO! GROUPS LINKS
|
- RE: [flexcoders] Strange behaviour when using a label func in ... Matt Chotin
-