[flexcoders] Re: Scroll Parent Canvas from Datagrid Drag and Drop...

2010-07-12 Thread shahjitesh
Did anyone encountered such scenario.

> How can I scroll parentDocument canvas when I perform Drag and Drop in
> DataGrid.
> 
> 
> 
> First MXML
> There is creationComplete Script which adds Second mxml as child
>  height="5000" backgroundAlpha="0" />
> 
> 
> 
> Second MXML (This MXML is used to move rows from one datagrid to another.
> Basically displaying 3 column layout where objects can be drag and dopped.
> When I drag top level level row to bottom I want ParentDocument canvas also
> to scroll, so that user can drop rows in 10th or 20th record which cannot be
> displayed on screen)
>  resize="resizeGrids()">
> 
>  dataProvider="{grid1XMLData}" paddingTop="0" paddingBottom="0"
> variableRowHeight="true" rowHeight="500"  x="5" y="5" width="33%"
> height="100%" showHeaders="false" dragEnabled="true" dragMoveEnabled="true"
> dropEnabled="true" borderStyle="none" visible="false" rollOverColor="white"
> alternatingItemColors="#FF">
> 
>  itemRenderer="components.ShowWidgetData" />
> 
> 
> 
> 
> 
>  id="dbGrid2" dataProvider="{grid2XMLData}"  paddingTop="0" paddingBottom="0"
> variableRowHeight="true" rowHeight="500"  backgroundAlpha="0" x="5" y="5"
> width="33%" height="100%" showHeaders="false" dragEnabled="true"
> dragMoveEnabled="true" dropEnabled="true" borderStyle="none"
> visible="false"  rollOverColor="white" alternatingItemColors="#FF">
> 
> 
>  itemRenderer="components.ShowWidgetData"/>
> 
> 
> 
> 
>  dataProvider="{grid3XMLData}" paddingTop="0" paddingBottom="0"
> variableRowHeight="true" rowHeight="500" backgroundAlpha="0" x="5" y="5"
> width="33%" height="100%" showHeaders="false" dragEnabled="true"
> dragMoveEnabled="true" dropEnabled="true" borderStyle="none"
> visible="false"  rollOverColor="white" alternatingItemColors="#FF">
> 
> 
> 
>  itemRenderer="components.ShowWidgetData" />
> 
> 
> 
> 
> 
> 




Re: [flexcoders] Is there a way to tell flash NOT to render a certain area?

2010-07-12 Thread Alex Harui
I’m having trouble picturing an accordion with scrollbars.  But if it did, why 
wouldn’t the scrollbar be tuned for the total number of children?  Why are 
children being added as you scroll?


On 7/12/10 6:59 PM, "dorkiedorkfromdorkt...@gmail.com" 
 wrote:






In that case, I'll elaborate on the situation...

I am using a horizontal Accordion component with newest items to the right. 
When you scroll left you get to a location where more items are added. As you 
add each item the scrollbar thumb track jumps to the right and then jumps back 
to where the mouse is. This happens every time a new item is added to the 
accordion.


On Mon, Jul 12, 2010 at 6:35 PM, Alex Harui  wrote:





Flash renders what is visible and on the display list.  UIComponent is 
invisible until creationComplete and theoretically, it and all of its children 
shouldn’t be changing after then.  Or make it visible=false until you know it 
is ready.



On 7/12/10 2:37 PM, "dorkiedorkfromdorkt...@gmail.com 
 " http://dorkiedorkfromdorkt...@gmail.com> > wrote:






There's a component that I'm adding child components too it. When I do this 
there's a flash as the component is added and resized and then put into the 
right position. Is there a way to prevent a square area from being rendered for 
a second or two? I can fix the issue but I'd have to go into UIComponent and 
mess with the base classes. Since I've run into this before (elastic race 
track) and will in the future its seems a reasonable request.





--
Alex Harui
Flex SDK Team
Adobe System, Inc.
http://blogs.adobe.com/aharui


Re: [flexcoders] Is there a way to tell flash NOT to render a certain area?

2010-07-12 Thread dorkie dork from dorktown
In that case, I'll elaborate on the situation...

I am using a horizontal Accordion component with newest items to the right.
When you scroll left you get to a location where more items are added. As
you add each item the scrollbar thumb track jumps to the right and then
jumps back to where the mouse is. This happens every time a new item is
added to the accordion.


On Mon, Jul 12, 2010 at 6:35 PM, Alex Harui  wrote:

>
>
> Flash renders what is visible and on the display list.  UIComponent is
> invisible until creationComplete and theoretically, it and all of its
> children shouldn’t be changing after then.  Or make it visible=false until
> you know it is ready.
>
>
>
> On 7/12/10 2:37 PM, "dorkiedorkfromdorkt...@gmail.com" <
> dorkiedorkfromdorkt...@gmail.com> wrote:
>
>
>
>
>
>
> There's a component that I'm adding child components too it. When I do this
> there's a flash as the component is added and resized and then put into the
> right position. Is there a way to prevent a square area from being rendered
> for a second or two? I can fix the issue but I'd have to go into UIComponent
> and mess with the base classes. Since I've run into this before (elastic
> race track) and will in the future its seems a reasonable request.
>
>
>
>
>
> --
> Alex Harui
> Flex SDK Team
> Adobe System, Inc.
> http://blogs.adobe.com/aharui
>  
>


[flexcoders] Display the Legend of each line series

2010-07-12 Thread Didi Tonfack
when i add  the tag  which myChart 
represent the id of the lineChart, 

i have this error:

 TypeError:Error #1034: Type Coercion failed: cannot convert 
mx.charts.chartClasses::legendd...@cc33701 to mx.charts.ChartItem.

i tried to add the import like 
import mx.charts.Legend;
import mx.charts.LegendItem;
import mx.charts.chartClasses.LegendData;

but the error still appear

thank you in advance

that is the code:
-LabelRenderer2.as
package
{

import flash.display.Graphics;
import flash.geom.Rectangle;
import mx.charts.ChartItem;
import mx.charts.chartClasses.GraphicsUtilities;
import mx.core.IDataRenderer;
import mx.graphics.IFill;
import mx.graphics.IStroke;
import mx.skins.ProgrammaticSkin;
import mx.controls.Label;
import  mx.core.UIComponent;
import mx.charts.LineChart;
import mx.charts.series.items.LineSeriesItem;
import mx.charts.Legend;
import mx.charts.LegendItem;
import mx.charts.chartClasses.LegendData;

public class LabeledRenderer2 extends UIComponent implements IDataRenderer
{
private var _label:Label;

public function
 LabeledRenderer2():void
{
super();
_label = new Label();
addChild(_label);
_label.setStyle("color",0x00);
}
private var _chartItem:ChartItem;

public function get data():Object
 {
return _chartItem;
}

public function set data(value:Object):void
{
if (_chartItem == value)
return;
_chartItem = ChartItem(value);

if(_chartItem != null)
_label.text = LineSeriesItem(_chartItem).yValue.toString();
}

private static const fills:Array = [0xFF,0x00FF00,0xFF,
 0x00,0xFF00FF,0x00,
0xAAFFAA,0xFF,0xFF]; 
override protected function updateDisplayList(unscaledWidth:Number,
 
 unscaledHeight:Number):void
{
super.updateDisplayList(unscaledWidth, unscaledHeight);
  

_label.setActualSize(_label.getExplicitOrMeasuredWidth(),_label.getExplicitOrMeasuredHeight());

_label.move(unscaledWidth - _label.getExplicitOrMeasuredWidth(),
unscaledHeight/2 - _label.getExplicitOrMeasuredHeight()/2);
}

}

}


LineChart.mxml-



import mx.graphics.Stroke;

 [Bindable]
public var expenses:Object = [{Month: "Jan", Profit: 2000, Expenses: 
1500, Amount: 450},
  {Month: "Feb", Profit: 1000, Expenses: 200, Amount: 600},
  {Month: "Mar",
 Profit: 1500, Expenses: 500, Amount: 300}];

public var s:Stroke = new Stroke(0x001100); 


















**
message error :
TypeError: Error #1034: Echec de la contrainte de type : conversion de 
mx.charts.chartClasses::legendd...@9ad4381 en mx.charts.ChartItem impossible.
at LabelRenderer2/set data()[D:\LabelChart\src\LabelRenderer2.as:31]
at mx.charts::LegendItem/set 
legendData()[C:\work\flex\dmv_automation\projects\datavisualisation\src\mx\charts\LegendItem.as:254]

at  
mx.charts::Legend/addLegendItem()[C:\work\flex\dmv_automation\projects\datavisualisation\src\mx\charts\Legend.as:651]

at 
mx.charts::Legend/populateFromArray()[C:\work\flex\dmv_automation\projects\datavisualisation\src\mx\charts\Legend.as:678]

at 
mx.charts::Legend/commitProperties()[C:\work\flex\dmv_automation\projects\datavisualisation\src\mx\charts\Legend.as:449]

at 
mx.core::UIComponent/validateProperties()[C:\autobuild\3.2.0\frameworks\projects\framework\src\mx\core\UIComponent.as:5807]

at 
mx.managers::LayoutManager/validateProperties()[C:\autobuild\3.2.0\frameworks\projects\framework\src\mx\managers\LayoutManager.as:539]

at 
mx.managers::LayoutManager/doPhasedInstantiation()[C:\autobuild\3.2.0\frameworks\projects\framework\src\mx\managers\LayoutManager.as:659]

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] Is there a way to tell flash NOT to render a certain area?

2010-07-12 Thread Alex Harui
Flash renders what is visible and on the display list.  UIComponent is 
invisible until creationComplete and theoretically, it and all of its children 
shouldn’t be changing after then.  Or make it visible=false until you know it 
is ready.


On 7/12/10 2:37 PM, "dorkiedorkfromdorkt...@gmail.com" 
 wrote:






There's a component that I'm adding child components too it. When I do this 
there's a flash as the component is added and resized and then put into the 
right position. Is there a way to prevent a square area from being rendered for 
a second or two? I can fix the issue but I'd have to go into UIComponent and 
mess with the base classes. Since I've run into this before (elastic race 
track) and will in the future its seems a reasonable request.





--
Alex Harui
Flex SDK Team
Adobe System, Inc.
http://blogs.adobe.com/aharui


Re: [flexcoders] Flex print Without Dialog Box ?

2010-07-12 Thread Oleg Sivokon
Hi. I remember that MDM Zinc offered this (only for texts, not graphics) at
some point (of course, only for desktop applications). Other than that, I'd
say that if it is a browser based application, it should not be possible,
and if it's a desktop, you should be looking into making some custom wrapper
+ send it serialized data, like, maybe PDF or try to generate PS files...
both ways it looks like rather complex task.


[flexcoders] Re: Flashbuilder 4.0.1 debugger issue?

2010-07-12 Thread Richard Rodseth
He's also on Flash Player 10.1 and after deleting shared objects used by our
splash screen, the app is locking up earlier (i.e. before dismissing the
splash screen. Are there some changes I should know about relating to 10.1,
security sandboxes, Shared Objects and the 4.0.1 debugger?

On Mon, Jul 12, 2010 at 2:41 PM, Richard Rodseth  wrote:

> A colleague is experiencing a problem where our app hangs the browser when
> run in the debugger, but not when launched in non-debug mode (from
> Flashbuilder). He's the only one on the team who started Flex work since the
> release of 4.0.1 so I'm wondering if there are any known problems that could
> explain this.
>
>
>


[flexcoders] Flashbuilder 4.0.1 debugger issue?

2010-07-12 Thread Richard Rodseth
A colleague is experiencing a problem where our app hangs the browser when
run in the debugger, but not when launched in non-debug mode (from
Flashbuilder). He's the only one on the team who started Flex work since the
release of 4.0.1 so I'm wondering if there are any known problems that could
explain this.


[flexcoders] Is there a way to tell flash NOT to render a certain area?

2010-07-12 Thread dorkie dork from dorktown
There's a component that I'm adding child components too it. When I do this
there's a flash as the component is added and resized and then put into the
right position. Is there a way to prevent a square area from being rendered
for a second or two? I can fix the issue but I'd have to go into UIComponent
and mess with the base classes. Since I've run into this before (elastic
race track) and will in the future its seems a reasonable request.


RE: [flexcoders] Re: Child of a child custom event handler

2010-07-12 Thread Scott
Nevermind:

 

systemManager.addEventListener(NewReservation.REFRESHEVENT,testevent);

 

THANKS Valdhor!

 

I'd still like to know how to debug the systemManager though...

 

sj

 

 



From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On
Behalf Of Scott
Sent: Monday, July 12, 2010 2:33 PM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] Re: Child of a child custom event handler

 

  

That makes a lot of sense. But...

 

How do I reference the popup at the top level?  Is it PopUpmanager.POPUP
or?

 

Is there a way to look at this in the debugger?

 

Thanks!

 



From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On
Behalf Of valdhor
Sent: Monday, July 12, 2010 11:06 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Child of a child custom event handler

 

  

Popup windows are parented by the system manager.

What you would need to do is add an event listener to the system manager
at the application level. When that event fires, you would then inject
it into your component.

--- In flexcoders@yahoogroups.com 
, "Scott"  wrote:
>
> 
> 
> I've got a parent component that contains a child panel that contains
a
> popup window. When the user enters the information and submits, I want
> to notify the top parent that a change has been made to refresh the
> other components.
> 
> 
> 
> grandparent->Panel->PopupWindow
> 
> 
> 
> In the popup window component I have:
> 
> 
> 
> [CDATA ...[
> 
> 
> 
> public static const REFRESHEVENT:String = "refreshItems";
> 
> 
> 
> protected function validateInput():int
> 
> {
> 
> var refreshScreen:Event = new Event( REFRESHEVENT, true, true );
> 
> 
> 
> ... validate code
> 
> 
> 
> dispatchEvent( refreshScreen );
> 
> ...
> 
> }
> 
> 
> 
> That should bubble all the way up now...
> 
> 
> 
> 
> 
> In the grandparent component I have:
> 
> 
> 
> init():void
> 
> {
> 
> addEventListener( NewReservation.REFRESHEVENT, testevent );
> 
> }
> 
> 
> 
> private function testevent():void
> 
> {
> 
> Alert.show("heard it");
> 
> }
> 
> 
> 
> 
> 
> Any ideas on how to troubleshoot this? I can't seem to find anything
in
> the debugger to watch this...
> 
> 
> 
> Thanks!
> 
> sj
>


-- 
This message has been scanned for viruses and 
dangerous content by MailScanner  , and is

believed to be clean. 




-- 
This message has been scanned for viruses and 
dangerous content by MailScanner  , and is

believed to be clean. 


RE: [flexcoders] Re: Child of a child custom event handler

2010-07-12 Thread Scott
That makes a lot of sense. But...

 

How do I reference the popup at the top level?  Is it PopUpmanager.POPUP
or?

 

Is there a way to look at this in the debugger?

 

Thanks!

 



From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On
Behalf Of valdhor
Sent: Monday, July 12, 2010 11:06 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Child of a child custom event handler

 

  

Popup windows are parented by the system manager.

What you would need to do is add an event listener to the system manager
at the application level. When that event fires, you would then inject
it into your component.

--- In flexcoders@yahoogroups.com 
, "Scott"  wrote:
>
> 
> 
> I've got a parent component that contains a child panel that contains
a
> popup window. When the user enters the information and submits, I want
> to notify the top parent that a change has been made to refresh the
> other components.
> 
> 
> 
> grandparent->Panel->PopupWindow
> 
> 
> 
> In the popup window component I have:
> 
> 
> 
> [CDATA ...[
> 
> 
> 
> public static const REFRESHEVENT:String = "refreshItems";
> 
> 
> 
> protected function validateInput():int
> 
> {
> 
> var refreshScreen:Event = new Event( REFRESHEVENT, true, true );
> 
> 
> 
> ... validate code
> 
> 
> 
> dispatchEvent( refreshScreen );
> 
> ...
> 
> }
> 
> 
> 
> That should bubble all the way up now...
> 
> 
> 
> 
> 
> In the grandparent component I have:
> 
> 
> 
> init():void
> 
> {
> 
> addEventListener( NewReservation.REFRESHEVENT, testevent );
> 
> }
> 
> 
> 
> private function testevent():void
> 
> {
> 
> Alert.show("heard it");
> 
> }
> 
> 
> 
> 
> 
> Any ideas on how to troubleshoot this? I can't seem to find anything
in
> the debugger to watch this...
> 
> 
> 
> Thanks!
> 
> sj
>




-- 
This message has been scanned for viruses and 
dangerous content by MailScanner  , and is

believed to be clean. 


[flexcoders] Scroll Parent Canvas from Datagrid Drag and Drop...

2010-07-12 Thread Jitesh Shah
How can I scroll parentDocument canvas when I perform Drag and Drop in
DataGrid.



First MXML
There is creationComplete Script which adds Second mxml as child




Second MXML (This MXML is used to move rows from one datagrid to another.
Basically displaying 3 column layout where objects can be drag and dopped.
When I drag top level level row to bottom I want ParentDocument canvas also
to scroll, so that user can drop rows in 10th or 20th record which cannot be
displayed on screen)






























Thanx and Regards
-- 
Jitesh Shah, PMP


Re: [flexcoders] How to make the element of list stressed and having the color blue (other style : bold, inline)

2010-07-12 Thread Alex Harui
I would use a custom itemrenderer.  There is no property or style you can set 
that will do it for you.


On 7/12/10 6:56 AM, "Nini7016 Nini7016"  wrote:






Hello

I have a list :
  

in the dataoprovider , i put an arrayCollection :
  public var arrayFileUpload : ArrayCollection;

 ...
 arrayFileUpload.addItem(fileRef.name +"  [size : "+ 
fileRef.size+"]");
listFileUpload.dataProvider = arrayFileUpload;
 !.

I would like that the element of the list "listFileUpload" will be bold and 
stressed

I don't find a style which can applicate to the dataprovider


Thanks








--
Alex Harui
Flex SDK Team
Adobe System, Inc.
http://blogs.adobe.com/aharui


[flexcoders] Re: Setting Different Style on ComboBox DropdownList

2010-07-12 Thread valdhor
Use an Item Renderer...

Test1.mxml:

http://www.adobe.com/2006/mxml";
layout="vertical">
 
 
 
 



Test1ItemRenderer.as:
package
{
 import mx.controls.*;

 public class Test1ItemRenderer extends Text
 {
 private var colorHex:String;

 public function Test1ItemRenderer()
 {
 super();
 }

 override public function set data(value:Object):void
 {
 if(value != null)
 {
 super.data = value;
 colorHex = value.ColorHex;
 }
 }

 override protected function
updateDisplayList(unscaledWidth:Number, unscaledHeight:Number):void
 {
 super.updateDisplayList(unscaledWidth, unscaledHeight);
 setStyle("color", colorHex);
 }
 }
}


--- In flexcoders@yahoogroups.com, Angelo Anolin 
wrote:
>
> Hi Flexcoders,
>
> How would I be able to set different styles on the list of a combo box
based on
> the values for the binding list to that?
>
> For example, I have some data retrieved as follows:
>
> ColorName  ColorHex
> Red#FF
> Blue   #FF
> Yellow #00
>
> And I am binding it to the combo box.
>
> Now When I show the list of the combo box, the LabelField maps to the
ColorName
> column and I want to display the ColorName based on its color as
defined in the
> ColorHex column.
>
> Any tips?
>
> Thanks.
>



[flexcoders] Re: Child of a child custom event handler

2010-07-12 Thread valdhor
Popup windows are parented by the system manager.

What you would need to do is add an event listener to the system manager at the 
application level. When that event fires, you would then inject it into your 
component.

--- In flexcoders@yahoogroups.com, "Scott"  wrote:
>
>  
> 
> I've got a parent component that contains a child panel that contains a
> popup window.  When the user enters the information and submits, I want
> to notify the top parent that a change has been made to refresh the
> other components.
> 
>  
> 
> grandparent->Panel->PopupWindow
> 
>  
> 
> In the popup window component I have:
> 
>  
> 
> [CDATA ...[
> 
>  
> 
> public static const REFRESHEVENT:String = "refreshItems";
> 
>  
> 
> protected function validateInput():int
> 
> {
> 
>   var refreshScreen:Event = new Event( REFRESHEVENT, true, true );
> 
>  
> 
> ... validate code
> 
>  
> 
>   dispatchEvent( refreshScreen );
> 
> ...
> 
> }
> 
>  
> 
> That should bubble all the way up now...
> 
>  
> 
>  
> 
> In the grandparent component I have:
> 
>  
> 
> init():void
> 
> {
> 
> addEventListener( NewReservation.REFRESHEVENT, testevent );
> 
> }
> 
>  
> 
> private function testevent():void
> 
> {
> 
>   Alert.show("heard it");
> 
> }
> 
>  
> 
>  
> 
> Any ideas on how to troubleshoot this?  I can't seem to find anything in
> the debugger to watch this...
> 
>  
> 
> Thanks!
> 
>  sj
>




[flexcoders] Child of a child custom event handler

2010-07-12 Thread Scott
 

I've got a parent component that contains a child panel that contains a
popup window.  When the user enters the information and submits, I want
to notify the top parent that a change has been made to refresh the
other components.

 

grandparent->Panel->PopupWindow

 

In the popup window component I have:

 

[CDATA ...[

 

public static const REFRESHEVENT:String = "refreshItems";

 

protected function validateInput():int

{

  var refreshScreen:Event = new Event( REFRESHEVENT, true, true );

 

... validate code

 

  dispatchEvent( refreshScreen );

...

}

 

That should bubble all the way up now...

 

 

In the grandparent component I have:

 

init():void

{

addEventListener( NewReservation.REFRESHEVENT, testevent );

}

 

private function testevent():void

{

  Alert.show("heard it");

}

 

 

Any ideas on how to troubleshoot this?  I can't seem to find anything in
the debugger to watch this...

 

Thanks!

 sj



[flexcoders] Re: The lifespan of flex.

2010-07-12 Thread Netaman

The question you have to ask is how long will HTML5 be supported before HTML6-8 
takes over the browser, also it looks like not all implementations of HTML are 
the same, so more browser supported third party javascript addons to handle the 
multitude of html5 workarounds...

Flex is a fun language to code in and when it life is over it will create a 
vacuum for the next best application development environment, but by that time 
hopefully there will be direct connects to the brain for application 
development and some of the best development done while we sleep.

IMHO

Randy
--- In flexcoders@yahoogroups.com, Wesley Acheson  wrote:
>
> Hi,
> 
> One of our clients is expressing concerns over the over all lifespan of
> flex.
> 
> Some of his specific worries are to do with the way flash isn't allowed on
> certain apple mobile devices and the initial implementations of HTML5 which
> is obviously backed by the W3C.  Their concern is that flex won't be a
> supported product 5 years down the line and/or the changes in browser
> technology by that point will render flash obsolete.
> 
> Have any studies been done about the long term feasibility of flex?  Are
> Adobe commited to a long term existence of the product? Is there any public
> evidence of large firms using it successfully?
> 
> Regards,
> 
> Wesley Acheson
>




RE: [flexcoders] User Interface Design Groups

2010-07-12 Thread Gregor Kiddie
The IXDA lists are good places to ask this sort of question. Lots of
good people there.


I've been working on a little composite search UI component but it needs
polishing off and I wondered if there were any groups out there that
could help with this sort of thing? Does anyone know of any?




 



RE: [flexcoders] loading image from url for groundoverlay on map

2010-07-12 Thread Gregor Kiddie
What's the size in pixels of the larger image? There is a hard pixel
limit in the Flash Player.

 

I'm trying to load an image (through url) as a groundoverlay on a google
map. I use a different url from the same domain like
(http://www.lamma.rete.toscana.it/models/marevento/wind10m_A_3.png) it
works perfectly but with the one I need (in the code) it doesn't. The
only difference is the image dimension (27.7k the one that works, 477k
the one that doesn't)




 



[flexcoders] Re: Flex Project Management App

2010-07-12 Thread Netaman
You can create a array of component names such as;
spark.components.Button
spark.components.TextInput
spark.components.CheckBox
spark.components.Label
spark.components.RadioButton
spark.components.DropDownList
mx.controls.DataGrid
spark.components.TextArea
mx.controls.DateField
then pass want you want into this function;
   private function makeElement(className:String, 
COMPONENTID:String):UIComponent {
var objClass:Class = getDefinitionByName( className ) as Class; 

if( objClass != null ) {
var newObject:UIComponent = UIComponent( new objClass() );
newObject.id = COMPONENTID;
newObject.name = COMPONENTID;
return newObject;
} 
else 
return null;
}


then create a switch that looks at the resulting element and add any styles, or 
other properties to the element, or other elements, and add then to your 
container. The dropdown and datagrid will require extra code to provide a 
dataprovider, and you will have to add the default skin by a setStyle, but that 
should get you going in the right direction.

one cavot is that the id is not searchable you will have to search by name in 
the container, if you want to change the element after you add it to the 
container.

I create elements dynamically by quering a database to create the elements 
needed in a flex applicaton, the structure and flow of forms are all in the 
database and I use flex to create the components on the fly...  

Randy 

--- In flexcoders@yahoogroups.com, Angelo Anolin  wrote:
>
> Hi FlexCoders,
> 
> I came across a Flex PM site and I would like to ask what are the necessary 
> controls / things I need to do to achieve the same application.
> 
> The site's page is:
> 
> http://www.radscientist.com/flexpm/demo/index.html
> 
> I am having problems re-creating those items which expands when the plus sign 
> is 
> clicked as well as adding new items when the Add Milestone button is clicked. 
>  How do I achieve adding controls on the fly on the application?
> 
> I hope you could provide some guidance on this.
> 
> Thanks.
> 
> Angelo
>




RE: [flexcoders] The lifespan of flex.

2010-07-12 Thread Gregor Kiddie
Not quite necro posting... (been on holiday so...)

 

The route back to your client is to show both penetration statistics for
Flash Player 10 versus HTML 5 compliant browsers. The 99% versus ~15% is
a big difference. You might want to point out the ROI of Flex is
drastically higher than HTML ( HTML5 especially as it is new ), the fact
that HTML 5 isn't set to be completely supported for years...

 

The best thing I've seen from friends who have had similar questions, is
when they deliver price estimates for an HTML 5 version versus a Flash
version for something moderately complicated. The differences have been
significant enough for their clients to drop the idea of HTML 5 very
quickly.

 

Gk.



[flexcoders] How to make the element of list stressed and having the color blue (other style : bold, inline)

2010-07-12 Thread Nini7016 Nini7016

Hello 

I have a list :
  

in the dataoprovider , i put an arrayCollection : 
  public var arrayFileUpload : ArrayCollection;

 ...
 arrayFileUpload.addItem(fileRef.name +"  [size : "+ 
fileRef.size+"]");
listFileUpload.dataProvider = arrayFileUpload;
.

I would like that the element of the list "listFileUpload" will be bold and 
stressed 

I don't find a style which can applicate to the dataprovider 


Thanks 


  

Re: [flexcoders] Re: remove border in a list ---make the border of the list invisible

2010-07-12 Thread dorkie dork from dorktown
borderStyle = "none"

On Mon, Jul 12, 2010 at 8:34 AM, Nini7016 Nini7016 <
nahloulaha...@hotmail.com> wrote:

>
>
> Thks
>
> I have to add borderThickness="0"
>
> --
> To: flexcoders@yahoogroups.com
> From: sminr...@gmail.com
> Date: Mon, 12 Jul 2010 13:18:18 +
> Subject: [flexcoders] Re: remove border in a list ---make the border of the
> list invisible
>
>
>
>  borderAlpha = 0
>
> --- In flexcoders@yahoogroups.com, Nini7016 Nini7016 
> wrote:
> >
> >
> > Hello
> >
> > I wouldn't like to display the border of a list
> >
> >  width="289" visible="false" editable="false"/>
> >
> > What attribut can i add it to do this (remove the border )
> >
> > Thank you
> >
> > NIni
> >
>
>
>   
>


RE: [flexcoders] Re: remove border in a list ---make the border of the list invisible

2010-07-12 Thread Nini7016 Nini7016

Thks

I have to add borderThickness="0"

To: flexcoders@yahoogroups.com
From: sminr...@gmail.com
Date: Mon, 12 Jul 2010 13:18:18 +
Subject: [flexcoders] Re: remove border in a list ---make the border of the 
list invisible


















 



  



  
  
  borderAlpha = 0



--- In flexcoders@yahoogroups.com, Nini7016 Nini7016  wrote:

>

> 

> Hello 

> 

> I wouldn't like to display the border of a list

> 

>  width="289" visible="false" editable="false"/>

> 

> What attribut can i add it to do this (remove the border )

> 

> Thank you 

> 

> NIni

>







 









  

[flexcoders] Re: remove border in a list ---make the border of the list invisible

2010-07-12 Thread sminrana
borderAlpha = 0

--- In flexcoders@yahoogroups.com, Nini7016 Nini7016  wrote:
>
> 
> Hello 
> 
> I wouldn't like to display the border of a list
> 
>  width="289" visible="false" editable="false"/>
> 
> What attribut can i add it to do this (remove the border )
> 
> Thank you 
> 
> NIni
>




[flexcoders] Re: remove border in a list ---make the border of the list invisible

2010-07-12 Thread sminrana
borderAlpha="0"

--- In flexcoders@yahoogroups.com, Nini7016 Nini7016  wrote:
>
> 
> Hello 
> 
> I wouldn't like to display the border of a list
> 
>  width="289" visible="false" editable="false"/>
> 
> What attribut can i add it to do this (remove the border )
> 
> Thank you 
> 
> NIni
>




Re: [flexcoders] Re: stopping accodion animation

2010-07-12 Thread dorkie dork from dorktown
i *haven't* been able to get this to work but you may,

accordion.endEffectsStarted();

you can also set the openDuration to 0 when you remove the children. then
set it back after. its a style so use:

accordion.setStyle("openDuration", 0);


On Mon, Jul 12, 2010 at 8:03 AM, valdhor wrote:

>
>
> Have a look at the TweenEvent.TWEEN_END, EffectEvent.EFFECT_END and
> TweenEvent.TWEEN_UPDATE events. They may send you in the right direction.
>
>
> --- In flexcoders@yahoogroups.com ,
> "flexwdw"  wrote:
> >
> > Hey all,
> >
> > I have to be able to dynamically remove children from an accordion
> container. Problem is, this causes a crash when the animation that runs on
> the selected child is running when I need to remove the panel. I see no way
> to force this animation to end or register for notification of it ending. Am
> I missing something? Turning animation off is not an option. I have worked
> around this to try to ensure it is impossible for a selected child change to
> occur anywhere near the remove child, but I would rather code this more
> defensively if possible.
> >
> > thanks!
> >
> > (ps, I am using 3.5 targeting FP 10.0.0)
> >
>
>  
>


[flexcoders] remove border in a list ---make the border of the list invisible

2010-07-12 Thread Nini7016 Nini7016

Hello 

I wouldn't like to display the border of a list



What attribut can i add it to do this (remove the border )

Thank you 

NIni
  

[flexcoders] Re: stopping accodion animation

2010-07-12 Thread valdhor
Have a look at the TweenEvent.TWEEN_END, EffectEvent.EFFECT_END and 
TweenEvent.TWEEN_UPDATE events. They may send you in the right direction.

--- In flexcoders@yahoogroups.com, "flexwdw"  wrote:
>
> Hey all,
> 
> I have to be able to dynamically remove children from an accordion container. 
>  Problem is, this causes a crash when the animation that runs on the selected 
> child is running when I need to remove the panel.  I see no way to force this 
> animation to end or register for notification of it ending.  Am I missing 
> something?  Turning animation off is not an option.  I have worked around 
> this to try to ensure it is impossible for a selected child change to occur 
> anywhere near the remove child, but I would rather code this more defensively 
> if possible.
> 
> thanks!
> 
> (ps, I am using 3.5 targeting FP 10.0.0)
>




[flexcoders] Re: any word on smooth mouse wheel scrolling?

2010-07-12 Thread valdhor
I would add an event listener for the mouse wheel event and then change
the delta (You'll have to experiment with the number to get it the way
you like; You may even need to change the += to a -=)...

addEventListener(MouseEvent.MOUSE_WHEEL, onMouseWheelEvent);

private function onMouseWheelEvent(event:MouseEvent):void
{
 event.delta += event.delta < 0 ? -50 : 50;
}


--- In flexcoders@yahoogroups.com, dorkie dork from dorktown
 wrote:
>
> does anyone have a fix for a smooth mouse wheel scroll in datagroups
or lists?
>
> right now it's jumping by 40px per scroll. it looks awful.
>