[flexcoders] Re: How to change headers title extending AdvancedDataGridHeaderRenderer

2010-01-05 Thread yossibaram

Does anybody knows,
How to make header title to be htmlText extending
AdvancedDataGridHeaderRenderer?

Please advise...

Thanks again

Jo 



RE: [flexcoders] Performance issues with data grid/advanced data grid

2010-01-05 Thread Alex Harui
Use the performance profiler to see if you can find places to optimize.

Alex Harui
Flex SDK Developer
Adobe Systems Inc.
Blog: http://blogs.adobe.com/aharui

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of sharath reddy
Sent: Tuesday, January 05, 2010 1:58 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Performance issues with data grid/advanced data grid



Hi All,

I'm loading an AdvancedDataGrid with an ArrayCollection of about 1350 items 
retrieved from the server. Each record has 5 fields, and I am using one very 
simple custom renderer. The grid doesn't seem to be able to handle these many 
records, and throws the following error:

Error #1502: A script has executed for longer than the default
timeout period of 15 seconds.

(I have attached the full stack trace at the end of the email)

I replaced ADG with the regular data grid, and experienced the same problem.

If I 'slice' the ArrayCollection and add only the first 1000 records, it seems 
to work (after some delay). The optimum performance seems to be with about 300 
records. I found a couple of work-arounds:

1. Currently, I set the height of the grid to be equal to the number of rows 
returned from the server. Scrollbars are turned off on the grid and turned on 
for the VBox that contains the grid.

If I set a fixed height for the data grid and turn ON the vertical scrollbars, 
the data renders correctly. I'm guessing that this allows the data grid to 
re-cycle renderers while scrolling and leads to more efficient performance. 
However, I don't want scrollbars on the grid, only on the parent container.

2. I can develop a paging implementation of the data grid, displaying about 500 
records on each page. Again, I would rather not do this.

Sorry for the long-winded post, any suggestions/workarounds to tackle this 
issue? Thanks for your help!

Sharath

Full Stack trace of the exception:

Error: Error #1502: A script has executed for longer than the default
timeout period of 15 seconds.
at
mx.managers.layoutClasses::PriorityQueue/removeLargestChild()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\managers\layoutClasses\PriorityQueue.as:145]
at mx.managers::LayoutManager/validateClient()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\managers\LayoutManager.as:940]
at mx.core::UIComponent/validateNow()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\core\UIComponent.as:5679]
at
mx.controls.dataGridClasses::DataGridBase/updateRendererDisplayList()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\dataGridClasses\DataGridBase.as:1184]
at
mx.controls.dataGridClasses::DataGridBase/drawItem()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\dataGridClasses\DataGridBase.as:1154]
at
mx.controls.dataGridClasses::DataGridBase/drawVisibleItem()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\dataGridClasses\DataGridBase.as:1127]
at
mx.controls.dataGridClasses::DataGridBase/makeRows()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\dataGridClasses\DataGridBase.as:708]
at
mx.controls.dataGridClasses::DataGridBase/makeRowsAndColumns()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\dataGridClasses\DataGridBase.as:593]
at mx.controls::DataGrid/makeRowsAndColumns()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\DataGrid.as:1538]
at
mx.controls.listClasses::ListBase/makeRowsAndColumnsWithExtraRows()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\listClasses\ListBase.as:1360]
at
mx.controls.listClasses::ListBase/updateDisplayList()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\listClasses\ListBase.as:3658]
at
mx.controls.dataGridClasses::DataGridBase/updateDisplayList()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\dataGridClasses\DataGridBase.as:581]
at mx.controls::DataGrid/updateDisplayList()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\DataGrid.as:1437]
at
mx.controls.listClasses::ListBase/validateDisplayList()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\listClasses\ListBase.as:3280]
at
mx.managers::LayoutManager/validateDisplayList()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\managers\LayoutManager.as:622]
at
mx.managers::LayoutManager/doPhasedInstantiation()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\managers\LayoutManager.as:695]
at Function/http://adobe.com/AS3/2006/builtin::apply()
at mx.core::UIComponent/callLaterDispatcher2()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\core\UIComponent.as:8628]
at mx.core::UIComponent/callLaterDispatcher()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\core\UIComponent.as:8568]



RE: [flexcoders] List control with different height items?

2010-01-05 Thread Alex Harui
variableRowHeight="true"

Alex Harui
Flex SDK Developer
Adobe Systems Inc.
Blog: http://blogs.adobe.com/aharui

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of gerry81611
Sent: Tuesday, January 05, 2010 4:57 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] List control with different height items?



Hello,

I am creating a list where each list item has a variable number of child 
elements. the itemrenderer creates images for each of child elements. So a list 
item might have 2 or 7 children in a Tile layout.

AFAIK the standard Flex List control takes the height of the tallest list item 
and applies that height to all list items, which results in extra space 
underneath the items with less children to display.

What would be involved in creating a list that let each item determine its own 
height?

thanks,

Gerry



[flexcoders] open source ad management system

2010-01-05 Thread ZIONIST
Any one know any opensource ad management system that works with coldfusion and 
flex like openAds(this works with php).



[flexcoders] Re: Stop ToolTips from Appearing on Certain Buttons.

2010-01-05 Thread jamesfin
close...use this

myButton.toolTip = null;



--- In flexcoders@yahoogroups.com, "taude1"  wrote:
>
> That doesn't work, it then creates the tooltip from the label value.
> 
> --- In flexcoders@yahoogroups.com, "Ariel J"  wrote:
> >
> > i believe you can do this by setting the tooltip text to the empty string
> > 
> > --- In flexcoders@yahoogroups.com, "taude1"  wrote:
> > >
> > > This seems like it should be easy. I know I can turn tooltips off with 
> > > the ToolTipManager, but that's applciation wide.  I want to disable 
> > > tooltips from certain Buttons.
> > > 
> > > I've implemented various combinations of tooltipShow, tooltipStart, 
> > > tooltipCreate on teh Button and tried setting the toolTips to NULL, to 
> > > creating a dummy toolTip, etc...
> > > 
> > > 
> > > Any ideas on how to totally supress tooltips?
> > > 
> > > Thanks,
> > >
> >
>




[flexcoders] Re: Stop ToolTips from Appearing on Certain Buttons.

2010-01-05 Thread taude1
That doesn't work, it then creates the tooltip from the label value.

--- In flexcoders@yahoogroups.com, "Ariel J"  wrote:
>
> i believe you can do this by setting the tooltip text to the empty string
> 
> --- In flexcoders@yahoogroups.com, "taude1"  wrote:
> >
> > This seems like it should be easy. I know I can turn tooltips off with the 
> > ToolTipManager, but that's applciation wide.  I want to disable tooltips 
> > from certain Buttons.
> > 
> > I've implemented various combinations of tooltipShow, tooltipStart, 
> > tooltipCreate on teh Button and tried setting the toolTips to NULL, to 
> > creating a dummy toolTip, etc...
> > 
> > 
> > Any ideas on how to totally supress tooltips?
> > 
> > Thanks,
> >
>




[flexcoders] List control with different height items?

2010-01-05 Thread gerry81611
Hello,

I am creating a list where each list item has a variable number of child 
elements. the itemrenderer creates images for each of child elements. So a list 
item might have 2 or 7 children in a Tile layout.

AFAIK the standard Flex List control takes the height of the tallest list item 
and applies that height to all list items, which results in extra space 
underneath the items with less children to display.

What would be involved in creating a list that let each item determine its own 
height?


thanks,


Gerry



[flexcoders] AdvancedDataGridRendererProvider woes with Browser Resize

2010-01-05 Thread davisford
Hi I have an ADG with 6 columns.  3 of the columns have a custom 
AdvancedDataGridRendererProvider.

Everything works fine for me except when I resize the browser, the grid paints 
things in the wrong place.  Note that this is after all the data has been 
loaded -- although I understand the renderers seem to be lazily initialized 
(e.g. if you scroll down).

If I scroll up and down, I never see this problem.  I can only seem to make it 
happen if I really drag the corner of the browser all around and then scroll up 
and down.

Interestingly enough, I see this problem in my swf hosted in IE8 and Firefox 
3.5, but I can't reproduce it in Chrome for whatever reason.

I don't have really good insight on where/how to approach solving this issue, 
so I was hoping someone on the group might throw me some pointers on things to 
try?

Thanks in advance,
Davis



[flexcoders] Performance issues with data grid/advanced data grid

2010-01-05 Thread sharath reddy
Hi All,

I'm loading an AdvancedDataGrid with an ArrayCollection of about 1350 items 
retrieved from the server. Each record has 5 fields, and I am using one very 
simple custom renderer. The grid doesn't seem to be able to handle these many 
records, and throws the following error:

Error #1502: A script has executed for longer than the default
timeout period of 15 seconds. 

(I have attached the full stack trace at the end of the email)

I replaced ADG with the regular data grid, and experienced the same problem. 

If I 'slice' the ArrayCollection and add only the first 1000 records, it seems 
to work (after some delay). The optimum performance seems to be with about 300 
records. I found a couple of work-arounds:

1. Currently, I set the height of the grid to be equal to the number of rows 
returned from the server. Scrollbars are turned off on the grid and turned on 
for the VBox that contains the grid. 

If I set a fixed height for the data grid and turn ON the vertical scrollbars, 
the data renders correctly. I'm guessing that this allows the data grid to 
re-cycle renderers while scrolling and leads to more efficient performance. 
However, I don't want scrollbars on the grid, only on the parent container. 

2. I can develop a paging implementation of the data grid, displaying about 500 
records on each page. Again, I would rather not do this. 

Sorry for the long-winded post, any suggestions/workarounds to tackle this 
issue? Thanks for your help!

Sharath

Full Stack trace of the exception:

Error: Error #1502: A script has executed for longer than the default
timeout period of 15 seconds.
  at
mx.managers.layoutClasses::PriorityQueue/removeLargestChild()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\managers\layoutClasses\PriorityQueue.as:145]
  at mx.managers::LayoutManager/validateClient()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\managers\LayoutManager.as:940]
  at mx.core::UIComponent/validateNow()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\core\UIComponent.as:5679]
  at
mx.controls.dataGridClasses::DataGridBase/updateRendererDisplayList()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\dataGridClasses\DataGridBase.as:1184]
  at
mx.controls.dataGridClasses::DataGridBase/drawItem()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\dataGridClasses\DataGridBase.as:1154]
  at
mx.controls.dataGridClasses::DataGridBase/drawVisibleItem()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\dataGridClasses\DataGridBase.as:1127]
  at
mx.controls.dataGridClasses::DataGridBase/makeRows()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\dataGridClasses\DataGridBase.as:708]
  at
mx.controls.dataGridClasses::DataGridBase/makeRowsAndColumns()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\dataGridClasses\DataGridBase.as:593]
  at mx.controls::DataGrid/makeRowsAndColumns()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\DataGrid.as:1538]
  at
mx.controls.listClasses::ListBase/makeRowsAndColumnsWithExtraRows()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\listClasses\ListBase.as:1360]
  at
mx.controls.listClasses::ListBase/updateDisplayList()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\listClasses\ListBase.as:3658]
  at
mx.controls.dataGridClasses::DataGridBase/updateDisplayList()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\dataGridClasses\DataGridBase.as:581]
  at mx.controls::DataGrid/updateDisplayList()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\DataGrid.as:1437]
  at
mx.controls.listClasses::ListBase/validateDisplayList()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\controls\listClasses\ListBase.as:3280]
  at
mx.managers::LayoutManager/validateDisplayList()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\managers\LayoutManager.as:622]
  at
mx.managers::LayoutManager/doPhasedInstantiation()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\managers\LayoutManager.as:695]
  at Function/http://adobe.com/AS3/2006/builtin::apply()
  at mx.core::UIComponent/callLaterDispatcher2()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\core\UIComponent.as:8628]
  at mx.core::UIComponent/callLaterDispatcher()[C:\autobuild\3.2.0
\frameworks\projects\framework\src\mx\core\UIComponent.as:8568]





  


[flexcoders] Re: Stop ToolTips from Appearing on Certain Buttons.

2010-01-05 Thread Ariel J
i believe you can do this by setting the tooltip text to the empty string

--- In flexcoders@yahoogroups.com, "taude1"  wrote:
>
> This seems like it should be easy. I know I can turn tooltips off with the 
> ToolTipManager, but that's applciation wide.  I want to disable tooltips from 
> certain Buttons.
> 
> I've implemented various combinations of tooltipShow, tooltipStart, 
> tooltipCreate on teh Button and tried setting the toolTips to NULL, to 
> creating a dummy toolTip, etc...
> 
> 
> Any ideas on how to totally supress tooltips?
> 
> Thanks,
>




[flexcoders] Re: container layout performance: MXML or ActionScript?

2010-01-05 Thread zaproheeks
Thank you for your answer.

No question MXML can be easier. But is your layout static or dynamic? I.e. do 
you simply statically position the children in MXML and nothing else 
touches/moves them, or do you do a lot of repositioning / resizing / restyling 
of children depending on application logic right when you display the container?



--- In flexcoders@yahoogroups.com, "seanmcmonahan"  wrote:
>
> While I don't have any cold hard facts about MXML vs AS performance I'd wager 
> that, all things equal, AS out performs MXML.
> 
> As far as my practice, I typically use MXML for layout and do everything else 
> in AS.  Coming from a web dev/HTML background I find it very easy to 
> visualize a layout written in MXML and feel that any lost performance (which 
> is probably minimal) allows me increased productivity as a developer.
> 
> --- In flexcoders@yahoogroups.com, "zaproheeks"  wrote:
> >
> > Given two "almost identical" (more  on that below) container classes one 
> > implemented in MXML, the other in ActionScript, which one is likely to be 
> > more performant? 
> > 
> > I'm not a Flex expert, but I know that even if MXML "is" ActionScript, 
> > there a number of things that are quite different. For instance, the layout 
> > of components is entirely taken care by MXML while in AS3 we have to do it 
> > by hand. Also binding is much more natural and common in MXML (stuff like 
> > property="{object.value}") while typically (at least in my code) I have no 
> > Bindings in my AS3 classes.
> > 
> > Another difference is that if some of the contained objects are affected by 
> > runtime conditions, since MXML hides away how the layout is actually 
> > performed, I end up doing adjustments on Creation Complete event, which 
> > will cause new re-render events. If I had implemented the class directly in 
> > AS3 I could have done everything inside createChildren() and maybe it would 
> > have been more performant?
> > 
> > What's your experience / best practices toward MXML / AS3 containers and 
> > conditional layout?



Re: [flexcoders] NumericStepper and change event

2010-01-05 Thread Richard Rodseth
Turns out that this necessitates validation, and there doesn't appear to be
a way to access the raw text of a numeric stepper to pass to a
NumberValidator.

I started out with a NumericStepper (minValue 500)  in a form, and the
designer noted that the save button did not get enabled until you change
focus away from the numericstepper.

If I listen for keyDown and update the model, then you can't type "4000"
because stepper.value always returns something valid, so "4" results in 500.

Any ideas? I'm tempted to revert to a regular TextInput.

It seems like there should be a NumericStepper with built-in validation,
that fires valid/invalid events.


On Mon, Nov 9, 2009 at 11:27 PM, Alex Harui  wrote:

>
>
>  Maybe watch for keyDown
>
>
>
> Alex Harui
>
> Flex SDK Developer
>
> Adobe Systems Inc. 
>
> Blog: http://blogs.adobe.com/aharui
>
>
>
> *From:* flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] *On
> Behalf Of *Richard Rodseth
> *Sent:* Monday, November 09, 2009 9:19 AM
> *To:* flexcoders@yahoogroups.com
> *Subject:* [flexcoders] NumericStepper and change event
>
>
>
>
>
> Is there any way to get a NumericStepper to fire a change event on each
> keystroke?
>
> I got a bug report that the form save button is not enabled until the
> stepper loses focus.
>
>   
>


[flexcoders] using custom scrollbars

2010-01-05 Thread Slackware
Hi all, happy new year!!

I'm using a mx:VScrollBar to manage the scroll for a Canvas (with 
verticalScrollPolicy="off"), since I need to place the scrollbar off-setted 
from the Canvas.

This code works as expected (the canvas scrolls based on my vertical scroll 
bar):

MyCanvas.verticalScrollPosition = event.currentTarget.scrollPosition; 
//currentTarget is my VScrollBar

But this way, I still need to set the verticalScrollProperties "by hand". I 
mean, if I have a really big Canvas my scrollBar doesn't reflect the height on 
its thumb for example.

Is there any easy way to achieve this?

Many thanks.





[flexcoders] using custom scrollbars

2010-01-05 Thread Slackware
Hi all, happy new year!!

I'm using a mx:VScrollBar to manage the scroll for a Canvas (with 
verticalScrollPolicy="off"), since I need to place the scrollbar off-setted 
from the Canvas.

This code works as expected (the canvas scrolls based on my vertical scroll 
bar):

MyCanvas.verticalScrollPosition = event.currentTarget.scrollPosition; 
//currentTarget is my VScrollBar

But this way, I still need to set the verticalScrollProperties "by hand". I 
mean, if I have a really big Canvas my scrollBar doesn't reflect the height on 
its thumb for example.

Is there any easy way to achieve this?

Many thanks.





[flexcoders] Re: Local Windows services calls from Air

2010-01-05 Thread valdhor
You could take a look at http://merapiproject.net/

--- In flexcoders@yahoogroups.com, "method_air"  wrote:
>
> Is there a way to call out to a local Windows service (ie COM etc) from 
> within Air?
> 
> Thanks,
> 
> Philip
>




[flexcoders] Is my ItemRenderer on the last Row of data?

2010-01-05 Thread Matthew
Hi,

I know the answer to this question before asking it but hopefully someone has a 
found a way to do this. 

Is there a way to know (in my override of set data() method) whether my item 
renderer is rendering the last row of data? 

thanks for any help on this one,

matt



[flexcoders] How to line up data in two forms

2010-01-05 Thread mitchgrrt
I have two  forms that come from two different .mxml files, but are 
being displayed on one page, one above the other.  I'd like to make the labels 
and inputs line up between the two forms.  Is there an easy way to do it?  
Thanks.



[SPAM] [flexcoders] Re: how to open pdf, word file using flex

2010-01-05 Thread k.sigiscar



Hi,

Yes, you need to create a PDF template with Adobe Livecycle Designer with the 
relevant fields. Then your Flex app must send XML data to your PDF remote 
object (residing on the LCDS Server) with the name of the XML nodes matching 
those of the fields in the PDF template (for data binding).

I have written a number of recipes in the Flex Cookbook beta website about PDF 
generation.

LCDS: Using the PDFResourceServlet to read the generated PDF 

http://cookbooks.adobe.com/post_LCDS__Using_the_PDFResourceServlet_to_read_the_gen-13726.html


LCDS: Creating a PDF form with localized captions 

http://cookbooks.adobe.com/post_LCDS__Creating_a_PDF_form_with_localized_captions-13166.html


LCDS: Displaying a datagrid in a generated PDF 

http://cookbooks.adobe.com/post_LCDS__Displaying_a_datagrid_in_a_generated_PDF-13886.html


LCDS: Displaying pictures dynamically loaded by Flex in a generated PDF 

http://cookbooks.adobe.com/post_LCDS__Displaying_pictures_dynamically_loaded_by_Fl-13267.html

Best regards,
Karl Sigiscar.


--- In flexcoders@yahoogroups.com, "Tracy Spratt"  wrote:
>
> I just looked at it a little bit, and it appears to be a solution to a niche
> problem, and does require a lot of server-side work, including a pre-built
> PFD template of the Flex app without any data.
> 
>  
> 
> Tracy Spratt,
> 
> Lariat Services, development services available
> 
>   _  
> 
> From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On
> Behalf Of valdhor
> Sent: Wednesday, December 23, 2009 11:18 AM
> To: flexcoders@yahoogroups.com
> Subject: [SPAM] [flexcoders] Re: how to open pdf, word file using flex
> 
>  
> 
>   
> 
> http://www.adobe.
> 
> com/devnet/flex/articles/portable_ria.html looks cool. I haven't read
> through it yet but will have to see if it really REQUIRES LCDS.
> 
> --- In flexcod...@yahoogro  ups.com,
> "vikranth4u"  wrote:
> >
> > Hi
> > can anybody help me regarding how to write a code to open a pdf or doc
> file using flex
> >
>




[flexcoders] Flex Builder 3 Pro project preferences bug

2010-01-05 Thread Joel Stransky
I'm having the strangest issue with Flex Builder project properties.
If I right click on a project and choose properties, every section allows me
to make changes except for Flex Compiler. When I choose that section, the
'Apply' and 'OK' buttons dim out. Even if I don't change anything, choosing
another section pops up an error box entitled "Could Not Accept Changes"
with the message, "The Currently displayed page contains invalid values"

I've tried uninstalling/reinstalling Flex Builder 3 both with and without
removal of the settings file. I tried repairing permissions in Disk Utility
but nothing works.

Has anyone seen anything like this?

specs:
Mac OS X 10.6.2
Flex Builder 3 Professional [stand alone] (build 3.0.2.214193)

-- 
--Joel Stransky
stranskydesign.com


[flexcoders] Can I add icons to Checkbox filter?

2010-01-05 Thread Thomas Silvester
I ahve an ADG table with icons in some Columns as data , I was tring to add 
filtering for this columns , the text filtering works fine for columns which 
has String as data. Iwould like to add multiple filtering for the column with 
icons as the data, i can multiple filter these columns if i give the string 
value of the icon as the checkbox seleced value, but I want to add the icon 
itself to the checkbox filter insted of the String value of the icon and filter 
it , is this possible? Any help is appreciated.
 
For Example I have 
a checkbox with the image string value as "hicon1.png", "hicon2.png" etc and if 
i check or uncheck these valuse it is filtering correctly the icon columns , 
but I want to add the icon to this checkbox control instead of the above 
strings, how can i do that ? Also if I managed to add this do this filter the 
valuse as i select or unselect the icons?
  Ican not put the whole source since there are many files, but any idea on how 
to do this is appraciated.
thanks in advance,
Ann.
 
Code Sample  is below
 

http://www.adobe.com/2006/mxml"; width="{column.width}">
















 
 
 
 
file 2
 
package com.ca.controls.advancedDataGridClasses.filters
{
import controls.advancedDataGridClasses.MAdvancedDataGridColumn;
import controls.advancedDataGridClasses.MAdvancedDataGridEvent;

import flash.events.Event;

import mx.collections.ArrayCollection;
import mx.collections.Sort;
import mx.controls.Image;
import mx.controls.Alert;

/**
* The MultipleChoiceFilter class defines MAdvancedDataGrid column filter 
* exposing the list of different values appearing in MAdvancedDataGrid
* column and allowing user to select which values should be displayed.
* 
* This filter should be applied to columns containing repeating values.
*/
public class MultipleChoiceFilter extends ColumnFilterBase
{
/**
* Constructor.
*/
public function MultipleChoiceFilter(column:MAdvancedDataGridColumn)
{
super(column);
advancedDataGrid.addEventListener(MAdvancedDataGridEvent.ORIGINAL_COLLECTION_CHANGE,
 originalCollectionChandeHandler);
updateLabels();
}

/**
* List of all different labels appearing in column related to this filter.
*/
[Bindable]
public var labels:ArrayCollection;
[Bindable]
public var lbls:ArrayCollection;
[Bindable]
var lbl:String = "";


/**
* List of selected labels.
* Only items with labels from this list will be included in MAdvancedDataGrid 
data provider.
*/
[Bindable]
public var selectedLabels:ArrayCollection = new ArrayCollection();

/**
* Select given label by adding it to selectedLabels list.
*/
public function selectLabel(label:String):void
{
if (!selectedLabels.contains(label))
{
selectedLabels.addItem(label);
}
commitFilterChange();
}

/**
* Deselect given label by adding it to selectedLabels list.
*/
public function deselectLabel(label:String):void
{
if (selectedLabels.contains(label))
{
selectedLabels.removeItemAt(selectedLabels.getItemIndex(label));
}
commitFilterChange();
}

/**
* Select all labels.
*/
public function selectAll():void
{
for each (var label:String in labels)
{
if (!selectedLabels.contains(label))
{
selectedLabels.addItem(label);
}
}
commitFilterChange();
}

/**
* Deselect all labels.
*/
public function deselectAll():void
{
selectedLabels.removeAll();
commitFilterChange();
}

/**
* Update isActive and then inform MAdvancedDataGrid about the 
change to this filter.
*/
override protected function commitFilterChange():void
{
var active:Boolean = false;
for each (var label:String in labels)
{
if (!selectedLabels.contains(label))
{
active = true;
break;
}
}
_isActive = active;
super.commitFilterChange();
}

/**
* Update labels list by iterating through MAdvancedDataGrid original collection.
*/
protected function updateLabels():void
{
//TODO: save filter selection when data are updated
var nl:ArrayCollection = new ArrayCollection();
var labelArray:ArrayCollection = new ArrayCollection();
for each (var item:Object in advancedDataGrid.originalCollection)
{
var label:String = column.itemToLabel(item);
 
if (label && !nl.contains(label))
{
nl.addItem(label); 


}



}
nl.sort = new Sort();
nl.refresh(); 
labels = nl; 
deselectAll();
selectAll();
}

/**
* MAdvancedDataGrid original collection change event handler.
*/
protected function originalCollectionChandeHandler(event:Event):void
{
updateLabels();
}

/**
* Flag indicating wether this filter is active 
* i.e may eliminate some items from MAdvancedDataGrid data provider.
*/
[Bindable("filterChanged")]
override public function get isActive():Boolean
{
return _isActive;
}
/**
* @private
* Storage variable for isActive flag.
*/
protected var _isActive:Boolean = false;

/**
* Test if given MAdvancedDataGrid item should remain in MAdvancedDataGrid data 
provider.
*/
override public function filterFunction(obj:Object):Boolean

{

 
return selectedLabels.contains(column.itemToLabel(obj));
}
}
}
 
 

[flexcoders] Bar Chart with different colors

2010-01-05 Thread Shashi
Hi all,

  Can i have a bar chart with different colors along X zxis.


For example I have 12 variables in array like JAn,Feb,...
to be displayed in different colors

CAn anybody help.

Thanks



[flexcoders] Text color on a Menubar

2010-01-05 Thread Wally Kolcz
Is there a way to control the text color of the drop down labels in a 
? I can change the top level with 'color' but it also changes 
the drop down label color. OR is there a way to control the background 
color of the drop downs?

My menu bar is a dark blue so I am using a yellow for the label colors. 
However, that also makes the labels on the drop downs (which are white) 
also yellow and hard to read. Thanks.



[flexcoders] Stop ToolTips from Appearing on Certain Buttons.

2010-01-05 Thread taude1
This seems like it should be easy. I know I can turn tooltips off with the 
ToolTipManager, but that's applciation wide.  I want to disable tooltips from 
certain Buttons.

I've implemented various combinations of tooltipShow, tooltipStart, 
tooltipCreate on teh Button and tried setting the toolTips to NULL, to creating 
a dummy toolTip, etc...


Any ideas on how to totally supress tooltips?

Thanks,



[flexcoders] Re: container layout performance: MXML or ActionScript?

2010-01-05 Thread seanmcmonahan
While I don't have any cold hard facts about MXML vs AS performance I'd wager 
that, all things equal, AS out performs MXML.

As far as my practice, I typically use MXML for layout and do everything else 
in AS.  Coming from a web dev/HTML background I find it very easy to visualize 
a layout written in MXML and feel that any lost performance (which is probably 
minimal) allows me increased productivity as a developer.

--- In flexcoders@yahoogroups.com, "zaproheeks"  wrote:
>
> Given two "almost identical" (more  on that below) container classes one 
> implemented in MXML, the other in ActionScript, which one is likely to be 
> more performant? 
> 
> I'm not a Flex expert, but I know that even if MXML "is" ActionScript, there 
> a number of things that are quite different. For instance, the layout of 
> components is entirely taken care by MXML while in AS3 we have to do it by 
> hand. Also binding is much more natural and common in MXML (stuff like 
> property="{object.value}") while typically (at least in my code) I have no 
> Bindings in my AS3 classes.
> 
> Another difference is that if some of the contained objects are affected by 
> runtime conditions, since MXML hides away how the layout is actually 
> performed, I end up doing adjustments on Creation Complete event, which will 
> cause new re-render events. If I had implemented the class directly in AS3 I 
> could have done everything inside createChildren() and maybe it would have 
> been more performant?
> 
> What's your experience / best practices toward MXML / AS3 containers and 
> conditional layout?
>




[flexcoders] Re: Anyone using demonsterdebugger ?

2010-01-05 Thread seanmcmonahan
Yeah, the code I posted earlier is how you setup MonsterDebugger.  Here's the 
link I used to get rolling: http://demonsterdebugger.com/features/howitworks

--- In flexcoders@yahoogroups.com, "seanmcmonahan"  wrote:
>
> Love demonster -- saved butt so many times.
> 
> I believe you need to initialize the debugger.  Something like this (sorry, 
> typing on my phone, don't have the code in front of me);
> 
> var d:MonsterDebuggrr = new MonsterDebugger(this);
> 
> where "this" refers to the application.  I'll doublecheck my setup when I get 
> to the office.
> 
> --- In flexcoders@yahoogroups.com, Nick Middleweek  wrote:
> >
> > Hi,
> > 
> > I've installed the http://demonsterdebugger.com/ and my
> > MonsterDebugger.trace(this, "Hello World!");  works fine but I can't seem to
> > inspect any objects as explained here...
> > 
> > I just get a timeline thing moving along the bottom and the Hello World
> > message is displayed.
> > 
> > Is there anything specific I need to do or look out for?
> > 
> > 
> > Thanks for any help...
> > 
> > 
> > Cheers,
> > N
> >
>




[flexcoders] Return Path/Type of Remote Object calls

2010-01-05 Thread Dan Pride
I am trying to trace the return path of a Remote Object call and a little 
confused by the result.
If I set up the following
 
   



and Call VehicleRo.getVeh(VehicleId)

What is the path in the debugger to find the result? It populates a grid just 
fine with 
ItemTypesRO.getVeh.lastResult

And should it come back as an Array of Value Objects or Generic Objects?

Thanks
Dan Pride


  


[flexcoders] Re: Anyone using demonsterdebugger ?

2010-01-05 Thread seanmcmonahan
Love demonster -- saved butt so many times.

I believe you need to initialize the debugger.  Something like this (sorry, 
typing on my phone, don't have the code in front of me);

var d:MonsterDebuggrr = new MonsterDebugger(this);

where "this" refers to the application.  I'll doublecheck my setup when I get 
to the office.

--- In flexcoders@yahoogroups.com, Nick Middleweek  wrote:
>
> Hi,
> 
> I've installed the http://demonsterdebugger.com/ and my
> MonsterDebugger.trace(this, "Hello World!");  works fine but I can't seem to
> inspect any objects as explained here...
> 
> I just get a timeline thing moving along the bottom and the Hello World
> message is displayed.
> 
> Is there anything specific I need to do or look out for?
> 
> 
> Thanks for any help...
> 
> 
> Cheers,
> N
>




[flexcoders] Re: PowerPoint in a swf

2010-01-05 Thread gilbert_mizrahi
Convert the slides to swf. For that you can use swftools 
(http://www.swftools.org/) PDF2SWF commnad line program.

Gilbert

--- In flexcoders@yahoogroups.com, "Christophe"  
wrote:
>
> Hello, 
> 
> How to integrate a PowerPoint presentation in a SWF Flex application ? 
> 
> Do you know a component ?
> 
> Thank you,
> Christophe,
>




[flexcoders] Re: XMLListCollection Filter - Viewing a single child branch

2010-01-05 Thread invertedspear
The Flex framework has awesome XML functions, even straight up querying of XML. 
I use this all the time: var myXML:XML = XMLVar.node.node.(@nodeID == 5) which 
will give you just this section of your XML


  



  


I'm not sure if this solves your problem exactly, but its pretty powerful stuff.
--- In flexcoders@yahoogroups.com, "aaronmfoster"  wrote:
>
> I'm glad I got to this before anyone spent their precious time on it. 
> Unfortunately, the problem was not with my code but stemmed from my
> fundamental understanding (or misunderstanding) of an XMLListCollection.
> Turns out XMLListCollections aren't magical gateways into hierarchal
> data.  As far as I can tell, they are essentially flat structures that
> hold a reference to a list.  I'll explain my failed attempt and hope
> that it will help somebody avoid the same mistake.  Here's roughly what
> my data looks like:
> 
>  nodeId="4"/> nodeId="8"/> nodeId="10"/>
> I was trying to apply the following filter function on the
> XMLListCollection to view a single child branch:
> public function viewBranch(xmlItem:XML):Boolean {return
> xmlItem.descendants()@nodeid == selectedNodeId; // where selectedNodeId
> corresponds to the appropriate nodeId }
> The problem with this is there is only one object in the
> XMLListCollection and it is either filtered out or it is not.   Since
> the single list contains all values for nodeid, any proper value for
> selectedNodeId will result in the entire list being included in the
> view.  Ah well, live and learn.
> I've since moved away from XMLLists, but if anyone has an idea of how to
> perform the original task with XMLListCollections I'd love to hear it.
> Cheers,
> Aaron
> 
> --- In flexcoders@yahoogroups.com, "aaronmfoster" 
> wrote:
> >
> > Howdy everyone,
> >
> > I'm struggling with an XMLListCollection filter function.  My xml is
> similarly structured to this:
> >
> > 
> >
> >   
> >   
> >
> >
> >   
> >   
> >
> > 
> >
> > It consists of a root node, with zero or more child nodes.  The child
> nodes could also have zero or more child nodes.  Basically it's your run
> of the mill xml. =P
> >
> > I'm looking for a filter function which allows me to view a single
> child branch.  In other words filter out all but a particular child node
> and it's children.  Effectively it would turn the view into this:
> >
> > 
> >
> >
> > 
> >
> > The goal is to keep the original xml unaltered, while creating a view
> of a child node that appears to be the root.  The view will then be
> applied to several components.  Although I've struggled with with it, a
> filter seems like the simplest way to go.  I'd greatly appreciate any
> suggestions.
> >
> > Thanks,
> > Aaron
> >
>




[flexcoders] Re: embed mp3 have error : unsupported sampling rate

2010-01-05 Thread seanmcmonahan
I ran into this not too long ago myself.  I believe the maximum supported 
sampling rate in Flex is 44.1kHz.  

Your code looks just fine, the mp3 is just "off".  Fortunately you can change 
the sampling rate.  I'm not an audio guy so I'm not sure of all the 
implications of changing the sampling rate, but it's what I did when I ran into 
this problem and it worked out okay for me.  I used Audacity to edit my mp3, 
it's a free tool for this sort of thing.

--- In flexcoders@yahoogroups.com, "songhuanren"  wrote:
>
> code :
>   public function PalaceLibAssets()
>   {
>   }
>   
>   [Embed(source="sound/sound1.mp3")]
>   public static var sound1:Class;
> 
> but have error:
>  unsupported sampling rate
> 
> 
> where is wrong???thanks
>




[flexcoders] Re: File Locked in AIR after Saving File to Local File System using FileReferenc

2010-01-05 Thread seanmcmonahan
Since you are using AIR look at using File instead of FileReference.

--- In flexcoders@yahoogroups.com, "edlueze"  wrote:
>
> Hi Folks:
> 
> I am trying to use the FileReference.save() function in AIR to save an XML 
> object to the local file system. I'm using the following code:
> 
> 
> public static function exportAllTablesToLocalFile():void {
> 
> var xmlAllProjectFiles:XML = ;
>   
> //Consolidate all of the Project Files together
> xmlAllProjectFiles.appendChild( Alerts.xmlAlerts );
> xmlAllProjectFiles.appendChild( Charts.xmlCharts );
> //etc...
> 
> var fileReference:FileReference = new FileReference(); //FileReference 
> points to the local file
> fileReference.save(xmlAllProjectFiles, "AllProjectFiles.xml"); //Save the 
> table as a local file
> }
> 
> 
> This code works perfectly fine, but I've noticed that it will lock the file. 
> Consequently if I try and replace the file the operation will silently fail!
> 
> The same thing doesn't seem to happen using regular Flex within a browser 
> when I try it with similar test code.
> 
> Is this a problem with AIR or am I doing something wrong? Should I be closing 
> the file after it's been saved. Should I be doing something with the 
> FileReference complete message?
> 
> Thanks!
>




Re: [flexcoders] Flex 3.5 - And Text Flow

2010-01-05 Thread Andriy Panas
Hi Stephen,

Text flow is a feature of Text Layout Framework
http://opensource.adobe.com/wiki/display/tlf/Text+Layout+Framework

Here is
example of Text flow functionality in action:
http://blog.allurefx.com/2009/07/flex-4-threaded-text-using-textflow.html
http://ayonesoftware.com/blog/2009/08/linked-containers-in-flex-4-using-text-layout-framework/

Text Layout Framework can be used with Flex 3.2 SDK and higher
http://www.adobe.com/devnet/flex/articles/text_layout_framework_03.html

--
Best regards,
Andriy Panas



2010/1/5 criptopus 

>
>
> In Desktop Publishing packages you can flow text from one text block into
> another text block, does anybody know if this is possible in FLEX.
> Currently I have Flex 3.5 SDK and Flash 10 installed.
>
> - Stephen Brown
>
>  
>


[flexcoders] Flex 3.5 - And Text Flow

2010-01-05 Thread criptopus
In Desktop Publishing packages you can flow text from one text block into 
another text block, does anybody know if this is possible in FLEX.
Currently I have Flex 3.5 SDK and Flash 10 installed.

- Stephen Brown



[flexcoders] Re: Flex Progress bar stuck....

2010-01-05 Thread ag_rcuren
Sounds like you are not letting the UI update during your 15 seconds of work. 
Flash player is single threaded meaning if you tell a progress bar to animate 
but then call a method that takes 15 seconds to finish the progress bar will be 
blocked until that method is completed hence your progress bar will hang until 
the work is done.

Take a look at pseudo threading or some other way to break up your work across 
frames that way you can give the UI some time to update and that should fix 
your problem.

--- In flexcoders@yahoogroups.com, "niks_tree"  wrote:
>
> I wants to call a series of custom event. Those event have some work to do 
> which takes 12 to 15 sec. Now i wants to call a progress bar event on those 
> set of event call. But the problem is my progress bar got hang during that 
> event call. If i stop the set of events then the progress bar working good. I 
> also tried some priority values, and usecapture as true too. Can help me on 
> this problem.
>




[flexcoders] Re: Question about flex source

2010-01-05 Thread paulberesf...@rocketmail.com
I think you will find in this sort of case its for readability. 
The Event is probably highlighted there for the function its before.


--- In flexcoders@yahoogroups.com, "ztpi1"  wrote:
>
> I notice that the flex source files have commented out sections like this one:
> 
> 
> **
>   
>  *  Dispatched after the Application has been initialized,
>
>  *  processed by the LayoutManager, and attached to the display list. 
>
>  *
>
>  *  @eventType mx.events.FlexEvent.APPLICATION_COMPLETE   
>
>  */
> 
> 
> Is the @ symbol significant here? Does the compiler see the line with the @ 
> symbol or is it merely for reader information?
> 
> It is my understanding that the @ symbol denotes an XML attribute, is that 
> the correct interpretation?
>




[flexcoders] Tooltip shows on tree node

2010-01-05 Thread Tejas Patel
how to display tooltip details on the each node of Tree component?
tree structure is displayed by data fetch from database.
each node has different detail to show as tooltip.

any idea please?

Thank you.



  The INTERNET now has a personality. YOURS! See your Yahoo! Homepage. 
http://in.yahoo.com/

[flexcoders] drop on list items

2010-01-05 Thread ha...@rocketmail.com
Here is a screenshot of two Lists I have created:
http://screencast.com/t/YmY2YWE2M 
The dataProvider of the "Glyph Sequences" List is nested within that of
the "Glyph tables" list.
Here's the basic structure of the data:  
Each of these Lists allow drag-drop. Normally the drag-drop of List
items is limited to within that List. I use the following (very simple)
dragEnter event handler to do that:
private function limitDropToCurrent(event:DragEvent):void{
if(event.dragInitiator != event.target){  event.preventDefault(); }}

I need to add the ability to drop items from the "Glyph Sequences" List
onto specific items within the "Glyph Tables" list and copy the data
being dragged to that specific "table".
What would be the best way to go about this?
Thanks,Harbs


[flexcoders] container layout performance: MXML or ActionScript?

2010-01-05 Thread zaproheeks
Given two "almost identical" (more  on that below) container classes one 
implemented in MXML, the other in ActionScript, which one is likely to be more 
performant? 

I'm not a Flex expert, but I know that even if MXML "is" ActionScript, there a 
number of things that are quite different. For instance, the layout of 
components is entirely taken care by MXML while in AS3 we have to do it by 
hand. Also binding is much more natural and common in MXML (stuff like 
property="{object.value}") while typically (at least in my code) I have no 
Bindings in my AS3 classes.

Another difference is that if some of the contained objects are affected by 
runtime conditions, since MXML hides away how the layout is actually performed, 
I end up doing adjustments on Creation Complete event, which will cause new 
re-render events. If I had implemented the class directly in AS3 I could have 
done everything inside createChildren() and maybe it would have been more 
performant?

What's your experience / best practices toward MXML / AS3 containers and 
conditional layout?



[flexcoders] How to change headers title extending AdvancedDataGridHeaderRenderer

2010-01-05 Thread yossibaram
Hi,
My column renderer extends AdvancedDataGridHeaderRenderer.
I would like to set the headers title to be htmlText.
Even using 
override public function set data(value:Object):void

doesnt let me do that.

Please advise How to set the headers to support html tags,

Thanks

Jo



[flexcoders] Flex Progress bar stuck....

2010-01-05 Thread niks_tree
I wants to call a series of custom event. Those event have some work to do 
which takes 12 to 15 sec. Now i wants to call a progress bar event on those set 
of event call. But the problem is my progress bar got hang during that event 
call. If i stop the set of events then the progress bar working good. I also 
tried some priority values, and usecapture as true too. Can help me on this 
problem.



[flexcoders] Error(s) in "Passing multiple values back from an item editor" example

2010-01-05 Thread mmyszew
If the Flex 3 "Passing multiple values back from an item editor" example is run 
with the debugger, the following messages appear repeatedly.

warning: unable to bind to property 'State' on class 'Object' (class is not an 
IEventDispatcher)
warning: unable to bind to property 'City' on class 'Object' (class is not an 
IEventDispatcher)

In addition, If you enter a new city and immediately click the yellow 
background of the city/state cell, the new city doesn't show in the renderer. 
However, the new city is there if you get the editor to display again.

I'm a relative newbie and would like to use this example as a starting point 
for an application, but I hesitate to start with something that looks broken.

Your help would be much appreciated.

Mat Myszewski

Here's the code pasted from the Help files (two files).

http://www.adobe.com/2006/mxml";  
backgroundColor="yellow">






AL
AK
AR
CA
MA






http://www.adobe.com/2006/mxml";  
width="700">





  











   
  






[flexcoders] Channel.Security.Error : guidance please

2010-01-05 Thread Tim Romano
 If I understand this document correctly:

http://kb2.adobe.com/cps/142/tn_14213.html

the Channel.Security.Error ("Security error accessing url") that I get when 
trying to access a webservice hosted at www.flash-mx.com from my desktop 
FlashBuilder (beta 2) development environment is probably the result of there 
not being a crossdomain.xml policy file at the root of www.flash-mx.com that 
permits access from "*".

http://www.flash-mx.com/ws/months.cfc?wsdl";> 
 


Do RESTful webservices avoid cross-domain security issues when the SWF client 
is running on a domain other than the one hosting the webservice? 

Thanks


[flexcoders] Anyone using demonsterdebugger ?

2010-01-05 Thread Nick Middleweek
Hi,

I've installed the http://demonsterdebugger.com/ and my
MonsterDebugger.trace(this, "Hello World!");  works fine but I can't seem to
inspect any objects as explained here...

I just get a timeline thing moving along the bottom and the Hello World
message is displayed.

Is there anything specific I need to do or look out for?


Thanks for any help...


Cheers,
N